PluginProbe
Code Snippets / 3.10.2
Code Snippets v3.10.2
4.0.0-beta.2 3.10.2 3.10.1 3.10.0 3.10.0-beta.2 3.10.0-beta.1 4.0.0-beta.1 3.9.6 trunk 2.10.0 2.10.1 2.12.0 2.12.1 2.13.0 2.13.1 2.13.2 2.13.3 2.14.0 2.14.1 2.14.2 2.14.3 2.14.4 2.14.5 2.14.6 3.0.0 All 65 releases
code-snippets / js / types / Window.ts

Window.ts in Code Snippets 3.10.2, at js/types/Window.ts

116 lines 2.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import type { SnippetSchema } from './schema/SnippetSchema'
2 import type { ChangelogSchema, ImageLinkSchema } from './schema/WelcomeSchema'
3 import type Prism from 'prismjs'
4 import type tinymce from 'tinymce'
5 import type { Snippet } from './Snippet'
6 import type { SnippetView } from './SnippetView'
7 import type { CodeEditorInstance, EditorOption, WordPressCodeEditor } from './vendor/WordPressCodeEditor'
8 import type { WordPressEditor } from './vendor/WordPressEditor'
9
10 declare global {
11 interface Window {
12 readonly wp: {
13 readonly editor?: WordPressEditor
14 readonly codeEditor?: WordPressCodeEditor
15 readonly hooks?: {
16 addAction: (
17 hookName: string,
18 namespace: string,
19 callback: (data: { rest_nonce?: string }) => void
20 ) => void
21 }
22 }
23 readonly pagenow?: string
24 readonly ajaxurl: string
25 readonly tinymce?: tinymce.EditorManager
26 readonly wpActiveEditor?: string
27 code_snippets_editor_preview?: CodeEditorInstance
28 readonly code_snippets_editor_settings: EditorOption[]
29 CODE_SNIPPETS_PRISM?: typeof Prism
30 readonly CODE_SNIPPETS?: {
31 debug: boolean
32 isLicensed: boolean
33 hideUpsell: boolean
34 isCloudConnected: boolean
35 snippetView: SnippetView
36 restAPI: {
37 base: string
38 snippets: string
39 recentlyActive: string
40 preferences: string
41 importPlugins: string
42 importFiles: string
43 nonce: string
44 cloud: {
45 token: string
46 snippets: string
47 }
48 }
49 urls: {
50 plugin: string
51 manage: string
52 addNew: string
53 edit: string
54 welcome: string
55 import: string
56 settings: string | null
57 cloud: string
58 }
59 banner: {
60 key: string
61 start_datetime: { date: string, timezone_type: number, timezone: string }
62 end_datetime: { date: string, timezone_type: number, timezone: string }
63 text_free: string
64 action_url_free: string
65 action_label_free: string
66 text_pro: string
67 action_url_pro: string
68 action_label_pro: string
69 }
70 }
71 readonly CODE_SNIPPETS_MANAGE?: {
72 snippetsList?: Snippet[]
73 hasNetworkCap: boolean
74 hiddenColumns: string[]
75 listOrder?: string
76 truncateRowValues: number | string
77 snippetsPerPage: number
78 typeCounts?: Record<string, number>
79 cloudSearchPerPage: number
80 isSafeModeActive: boolean
81 bulkDownloadNonce: string
82 runOnceNonce?: string
83 supportsZipDownloads: boolean
84 editorTheme: string
85 }
86 readonly CODE_SNIPPETS_EDIT?: {
87 snippet: SnippetSchema
88 pageTitleActions: Record<string, string>
89 isLicensed: boolean
90 enableDownloads: boolean
91 activateByDefault: boolean
92 enableDescription: boolean
93 editorTheme: string
94 tagOptions: {
95 enabled: boolean
96 allowSpaces: boolean
97 availableTags: string[]
98 }
99 descEditorOptions: {
100 rows: number
101 mediaButtons: boolean
102 }
103 }
104 readonly CODE_SNIPPETS_WELCOME?: {
105 hero: {
106 name: string
107 follow_url: string
108 image_url: string
109 }
110 changelog: ChangelogSchema[]
111 features: ImageLinkSchema[]
112 partners: ImageLinkSchema[]
113 }
114 }
115 }
116