├── LICENSE
├── README.md
├── _build
├── build.config.php
├── build.transport.php
├── config
│ ├── categories.php
│ ├── current.project.php
│ ├── example.config.php
│ └── structures.config.php
├── data
│ ├── lector
│ │ └── transport.chunks.php
│ ├── mgr
│ │ └── transport.chunks.php
│ ├── properties
│ │ ├── properties.structures-lector.template.php
│ │ ├── properties.structures-slate.template.php
│ │ └── properties.structures.template.php
│ ├── slate
│ │ └── transport.chunks.php
│ └── structures
│ │ ├── transport.chunks.php
│ │ ├── transport.plugins.php
│ │ ├── transport.snippets.php
│ │ ├── transport.templates.php
│ │ └── transport.tvs.php
├── install.options
│ └── user.input.php
└── resolvers
│ ├── category.resolver.php
│ ├── plugin.resolver.php
│ ├── structures.resolver.php
│ └── tv.resolver.php
├── assets
└── components
│ └── structures
│ ├── css
│ ├── structures_all.css
│ ├── structures_all.min.css
│ └── structures_mgr.css
│ ├── gallery
│ ├── colorbox
│ │ ├── colorbox.css
│ │ └── images
│ │ │ ├── controls.png
│ │ │ ├── light-controls.png
│ │ │ └── loading.gif
│ ├── css
│ │ └── TinyJSONGallery.css
│ ├── images
│ │ ├── loader.gif
│ │ ├── nature
│ │ │ ├── Seaofclouds - 2880x1800.gif
│ │ │ └── WatercolorSunsetHD.gif
│ │ └── noImage.gif
│ ├── js
│ │ ├── TinyJSONGallery.js
│ │ ├── download.js
│ │ └── json2html.js
│ └── php
│ │ ├── TinyJSONGalleryConnector.php
│ │ └── index.html
│ ├── img
│ ├── blank.jpg
│ └── loader.gif
│ ├── js
│ ├── donshakespeare_plugins.min.js
│ ├── structures_all.js
│ ├── structures_all.min.js
│ └── tinyBlocks.js
│ ├── markdown
│ ├── Michelf
│ │ ├── Markdown.inc.php
│ │ ├── Markdown.php
│ │ ├── MarkdownExtra.inc.php
│ │ ├── MarkdownExtra.php
│ │ └── MarkdownInterface.php
│ └── parsedown
│ │ ├── Parsedown.php
│ │ └── ParsedownExtra.php
│ ├── rapidimage
│ └── tinyBlocksRapidImage.php
│ ├── tinymceskins
│ └── hamlet
│ │ ├── Variables.less
│ │ ├── content.inline.min.css
│ │ ├── content.min.css
│ │ ├── fonts
│ │ ├── readme.md
│ │ ├── tinymce-small.eot
│ │ ├── tinymce-small.json
│ │ ├── tinymce-small.svg
│ │ ├── tinymce-small.ttf
│ │ ├── tinymce-small.woff
│ │ ├── tinymce.eot
│ │ ├── tinymce.json
│ │ ├── tinymce.svg
│ │ ├── tinymce.ttf
│ │ └── tinymce.woff
│ │ ├── img
│ │ ├── anchor.gif
│ │ ├── loader.gif
│ │ ├── object.gif
│ │ └── trans.gif
│ │ ├── skin.ie7.min.css
│ │ ├── skin.json
│ │ └── skin.min.css
│ └── uploads
│ └── blank.png
└── core
└── components
└── structures
├── docs
├── changelog.txt
├── license.txt
├── readme.txt
└── tutorial.html
└── elements
├── chunks
├── st.ace_mirror_config.chunk.html
├── st.help_howto.chunk.html
├── st.importmarker_tpl.chunk.html
├── st.importwrapper_tpl.chunk.html
├── st.save_buttons.chunk.html
├── st.structures.chunk.html
└── st.tinymce_config.chunk.html
├── plugins
└── structures.plugin.php
├── snippets
└── structures.snippet.php
└── templates
├── structures-lector.template.html
└── structures.template.html
/README.md:
--------------------------------------------------------------------------------
1 | Structures Extra for MODX Revolution
2 | =======================================
3 |
4 | https://github.com/donShakespeare/Structures
5 |
6 | A fantastic new way to handle content in MODX.
7 |
--------------------------------------------------------------------------------
/_build/build.config.php:
--------------------------------------------------------------------------------
1 | 'Structures',
4 | );
5 | return $cats;
6 |
--------------------------------------------------------------------------------
/_build/config/current.project.php:
--------------------------------------------------------------------------------
1 | 'Structures', /* No spaces, no dashes */
17 | 'packageNameLower' => $packageNameLower,
18 | 'packageDescription' => 'A fantastic new way to enter content in MODX.',
19 | 'version' => '3.1.0',
20 | 'release' => 'beta1',
21 | 'author' => 'donShakespeare',
22 | 'email' => '',
23 | 'authorUrl' => 'https://github.com/donShakespeare/Structures',
24 | 'authorSiteName' => "Structures",
25 | 'packageDocumentationUrl' => 'https://github.com/donShakespeare/Structures/wiki',
26 | 'copyright' => '2016',
27 |
28 | /* no need to edit this except to change format */
29 | 'createdon' => strftime('%m-%d-%Y'),
30 |
31 | 'gitHubUsername' => '',
32 | 'gitHubRepository' => '',
33 |
34 | /* two-letter code of your primary language */
35 | 'primaryLanguage' => 'en',
36 |
37 | /* Set directory and file permissions for project directories */
38 | 'dirPermission' => 0755, /* No quotes!! */
39 | 'filePermission' => 0644, /* No quotes!! */
40 |
41 | /* Define source and target directories */
42 |
43 | /* path to MyComponent source files */
44 | 'mycomponentRoot' => $this->modx->getOption('mc.root', null,
45 | MODX_CORE_PATH . 'components/mycomponent/'),
46 |
47 | /* path to new project root */
48 | 'targetRoot' => MODX_ASSETS_PATH . 'mycomponents/' . $packageNameLower . '/',
49 |
50 |
51 | /* *********************** NEW SYSTEM SETTINGS ************************ */
52 |
53 | /* If your extra needs new System Settings, set their field values here.
54 | * You can also create or edit them in the Manager (System -> System Settings),
55 | * and export them with exportObjects. If you do that, be sure to set
56 | * their namespace to the lowercase package name of your extra */
57 |
58 | 'newSystemSettings' => array(),
59 |
60 | /* ************************ NEW SYSTEM EVENTS ************************* */
61 |
62 | /* Array of your new System Events (not default
63 | * MODX System Events). Listed here so they can be created during
64 | * install and removed during uninstall.
65 | *
66 | * Warning: Do *not* list regular MODX System Events here !!! */
67 |
68 | 'newSystemEvents' => array(),
69 |
70 | /* ************************ NAMESPACE(S) ************************* */
71 | /* (optional) Typically, there's only one namespace which is set
72 | * to the $packageNameLower value. Paths should end in a slash
73 | */
74 |
75 | 'namespaces' => array(
76 | 'structures' => array(
77 | 'name' => 'structures',
78 | 'path' => '{core_path}components/structures/',
79 | 'assets_path' => '{assets_path}components/structures/',
80 | ),
81 |
82 | ),
83 |
84 | /* ************************ CONTEXT(S) ************************* */
85 | /* (optional) List any contexts other than the 'web' context here
86 | */
87 |
88 | 'contexts' => array(),
89 |
90 | /* *********************** CONTEXT SETTINGS ************************ */
91 |
92 | /* If your extra needs Context Settings, set their field values here.
93 | * You can also create or edit them in the Manager (Edit Context -> Context Settings),
94 | * and export them with exportObjects. If you do that, be sure to set
95 | * their namespace to the lowercase package name of your extra.
96 | * The context_key should be the name of an actual context.
97 | * */
98 |
99 | 'contextSettings' => array(),
100 |
101 | /* ************************* CATEGORIES *************************** */
102 | /* (optional) List of categories. This is only necessary if you
103 | * need to categories other than the one named for packageName
104 | * or want to nest categories.
105 | */
106 |
107 | 'categories' => array(
108 | 'Structures' => array(
109 | 'category' => 'Structures',
110 | 'parent' => '' /* top level category */
111 | )
112 | ) ,
113 |
114 | /* *************************** MENUS ****************************** */
115 |
116 | /* If your extra needs Menus, you can create them here
117 | * or create them in the Manager, and export them with exportObjects.
118 | * Be sure to set their namespace to the lowercase package name
119 | * of your extra.
120 | *
121 | * Every menu should have exactly one action */
122 |
123 | 'menus' => array(),
124 |
125 |
126 | /* ************************* ELEMENTS **************************** */
127 |
128 | /* Array containing elements for your extra. 'category' is required
129 | for each element, all other fields are optional.
130 | Property Sets (if any) must come first!
131 |
132 | The standard file names are in this form:
133 | SnippetName.snippet.php
134 | PluginName.plugin.php
135 | ChunkName.chunk.html
136 | TemplateName.template.html
137 |
138 | If your file names are not standard, add this field:
139 | 'filename' => 'actualFileName',
140 | */
141 |
142 |
143 | 'elements' => array(),
144 | /* (optional) will make all element objects static - 'static' field above will be ignored */
145 | 'allStatic' => false,
146 |
147 |
148 | /* ************************* RESOURCES ****************************
149 | Important: This list only affects Bootstrap. There is another
150 | list of resources below that controls ExportObjects.
151 | * ************************************************************** */
152 | /* Array of Resource pagetitles for your Extra; All other fields optional.
153 | You can set any resource field here */
154 | 'resources' => array(),
155 |
156 |
157 | /* Array of languages for which you will have language files,
158 | * and comma-separated list of topics
159 | * ('.inc.php' will be added as a suffix). */
160 | 'languages' => array(),
161 | /* ********************************************* */
162 | /* Define optional directories to create under assets.
163 | * Add your own as needed.
164 | * Set to true to create directory.
165 | * Set to hasAssets = false to skip.
166 | * Empty js and/or css files will be created.
167 | */
168 | 'hasAssets' => true,
169 |
170 | 'assetsDirs' => array(
171 | /* If true, a default (empty) CSS file will be created */
172 | 'css' => true,
173 | 'gallery' => true,
174 | 'img' => true,
175 | 'js' => true,
176 | 'markdown' => true,
177 | 'rapidimage' => true,
178 | 'tinymceskins' => true,
179 | 'uploads' => true
180 | ),
181 | /* minify any JS files */
182 | 'minifyJS' => false,
183 | /* Create a single JS file from all JS files */
184 | 'createJSMinAll' => false,
185 | /* if this is false, regular jsmin will be used.
186 | JSMinPlus is slower but more reliable */
187 | 'useJSMinPlus' => false,
188 |
189 | /* These will automatically go under assets/components/yourcomponent/js/
190 | Format: directory:filename
191 | (no trailing slash on directory)
192 | if 'createCmpFiles is true, these will be ignored.
193 | */
194 | 'jsFiles' => array(),
195 |
196 | /* Desired CSS files */
197 | 'cssFiles' => array(),
198 |
199 | /* ********************************************* */
200 | /* Define basic directories and files to be created in project*/
201 |
202 | 'docs' => array(
203 | 'readme.txt',
204 | 'license.txt',
205 | 'changelog.txt',
206 | 'tutorial.html'
207 | ),
208 |
209 | /* (optional) Description file for GitHub project home page */
210 | 'readme.md' => true,
211 | /* assume every package has a core directory */
212 | 'hasCore' => true,
213 |
214 | /* ********************************************* */
215 | /* (optional) Array of extra script resolver(s) to be run
216 | * during install. Note that resolvers to connect plugins to events,
217 | * property sets to elements, resources to templates, and TVs to
218 | * templates will be created automatically -- *don't* list those here!
219 | *
220 | * 'default' creates a default resolver named after the package.
221 | * (other resolvers may be created above for TVs and plugins).
222 | * Suffix 'resolver.php' will be added automatically */
223 | 'resolvers' => array(
224 | 'default'
225 | ),
226 |
227 | /* (optional) Validators can abort the install after checking
228 | * conditions. Array of validator names (no
229 | * prefix of suffix) or '' 'default' creates a default resolver
230 | * named after the package suffix 'validator.php' will be added */
231 |
232 | 'validators' => array(),
233 |
234 | /* (optional) install.options is needed if you will interact
235 | * with user during the install.
236 | * See the user.input.php file for more information.
237 | * Set this to 'install.options' or ''
238 | * The file will be created as _build/install.options/user.input.php
239 | * Don't change the filename or directory name. */
240 | 'install.options' => 'install.options',
241 |
242 |
243 | /* Suffixes to use for resource and element code files (not implemented) */
244 | 'suffixes' => array(
245 | 'modPlugin' => '.php',
246 | 'modSnippet' => '.php',
247 | 'modChunk' => '.html',
248 | 'modTemplate' => '.html',
249 | 'modResource' => '.html',
250 | ),
251 |
252 |
253 | /* ********************************************* */
254 | /* (optional) Only necessary if you will have class files.
255 | *
256 | * Array of class files to be created.
257 | *
258 | * Format is:
259 | *
260 | * 'ClassName' => 'directory:filename',
261 | *
262 | * or
263 | *
264 | * 'ClassName' => 'filename',
265 | *
266 | * ('.class.php' will be appended automatically)
267 | *
268 | * Class file will be created as:
269 | * yourcomponent/core/components/yourcomponent/model/[directory/]{filename}.class.php
270 | * Note: If a CMP is being created, classes containing the
271 | * project name will be ignored here.
272 | *
273 | * Set to array() if there are no classes. */
274 | 'classes' => array(),
275 |
276 | /* ************************************
277 | * These values are for CMPs.
278 | * Set any of these to an empty array if you don't need them.
279 | * **********************************/
280 |
281 | /* If this is false, the rest of this section will be ignored */
282 |
283 | 'createCmpFiles' => false,
284 |
285 | /* IMPORTANT: The array values in the rest of
286 | this section should be all lowercase */
287 |
288 | /* This is the main action file for your component.
289 | It will automatically go in core/component/yourcomponent/
290 | */
291 |
292 | 'actionFile' => 'index.class.php',
293 |
294 | /* CSS file for CMP */
295 |
296 | 'cssFile' => 'mgr.css',
297 |
298 | /* These will automatically go to core/components/yourcomponent/processors/
299 | format directory:filename
300 | '.class.php' will be appended to the filename
301 |
302 | Built-in processor classes include getlist, create, update, duplicate,
303 | import, and export. */
304 |
305 | 'processors' => array(
306 | 'mgr/snippet:getlist',
307 | 'mgr/snippet:changecategory',
308 | 'mgr/snippet:remove',
309 |
310 | 'mgr/chunk:getlist',
311 | 'mgr/chunk:changecategory',
312 | 'mgr/chunk:remove',
313 | ),
314 |
315 | /* These will automatically go to core/components/yourcomponent/controllers[/directory]/filename
316 | Format: directory:filename */
317 |
318 | 'controllers' => array(
319 | ':home.class.php',
320 | ),
321 |
322 | /* These will automatically go in assets/components/yourcomponent/ */
323 |
324 | 'connectors' => array(
325 | 'connector.php'
326 |
327 | ),
328 | /* These will automatically go to assets/components/yourcomponent/js[/directory]/filename
329 | Format: directory:filename */
330 |
331 | 'cmpJsFiles' => array(
332 | ':structures.class.js',
333 | 'sections:home.js',
334 | 'widgets:home.panel.js',
335 | 'widgets:snippet.grid.js',
336 | 'widgets:chunk.grid.js',
337 | ),
338 |
339 | /* These go to core/components/componentName/templates/
340 | * The format is:
341 | * filename:content
342 | * content is optional
343 | */
344 |
345 | 'cmpTemplates' => array (),
346 |
347 |
348 | /* *******************************************
349 | * These settings control exportObjects.php *
350 | ******************************************* */
351 | /* ExportObjects will update existing files. If you set dryRun
352 | to '1', ExportObjects will report what it would have done
353 | without changing anything. Note: On some platforms,
354 | dryRun is *very* slow */
355 |
356 | 'dryRun' => '0',
357 |
358 | /* Array of elements to export. All elements set below will be handled.
359 | *
360 | * To export resources, be sure to list pagetitles and/or IDs of parents
361 | * of desired resources
362 | */
363 | 'process' => array(
364 | // 'contexts',
365 | 'snippets',
366 | 'plugins',
367 | 'templateVars',
368 | 'templates',
369 | 'chunks',
370 | // 'resources',
371 | // 'propertySets'
372 | // 'systemSettings',
373 | // 'contextSettings',
374 | // 'systemEvents',
375 | // 'menus'
376 | ),
377 | /* Array of resources to process. You can specify specific resources
378 | or parent (container) resources, or both.
379 |
380 | They can be specified by pagetitle or ID, but you must use the same method
381 | for all settings and specify it here. Important: use IDs if you have
382 | duplicate pagetitles */
383 | 'getResourcesById' => false,
384 |
385 | 'exportResources' => '',
386 | /* Array of resource parent IDs to get children of. */
387 | 'parents' => array(),
388 | /* Also export the listed parent resources
389 | (set to false to include just the children) */
390 | 'includeParents' => false,
391 |
392 |
393 | /* ******************** LEXICON HELPER SETTINGS ***************** */
394 | /* These settings are used by LexiconHelper */
395 | 'rewriteCodeFiles' => false, /* remove ~~descriptions */
396 | 'rewriteLexiconFiles' => true, /* automatically add missing strings to lexicon files */
397 | /* ******************************************* */
398 |
399 | /* Array of aliases used in code for the properties array.
400 | * Used by the checkproperties utility to check properties in code against
401 | * the properties in your properties transport files.
402 | * if you use something else, add it here (OK to remove ones you never use.
403 | * Search also checks with '$this->' prefix -- no need to add it here. */
404 | 'scriptPropertiesAliases' => array(
405 | 'props',
406 | 'sp',
407 | 'config',
408 | 'scriptProperties'
409 | ),
410 | );
411 |
412 | return $components;
--------------------------------------------------------------------------------
/_build/data/lector/transport.chunks.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $chunks */
24 |
25 |
26 | $chunks = array();
27 |
28 | $chunks[1] = $modx->newObject('modChunk');
29 | $chunks[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'st.lector_importWrapper_tpl',
33 | 'description' => 'Template used by Structures to wrap content that has MODX comment tag, [[-TB-MARKER]]. Use the import tool or use Manager resource url parameter &autoImport. This chunk is sample using the Markdown block/structure.',
34 | 'properties' =>
35 | array (
36 | ),
37 | ), '', true, true);
38 | $chunks[1]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_importwrapper_tpl.chunk.html'));
39 |
40 | $chunks[2] = $modx->newObject('modChunk');
41 | $chunks[2]->fromArray(array (
42 | 'id' => 2,
43 | 'property_preprocess' => false,
44 | 'name' => 'st.lector_structures',
45 | 'description' => 'New blocks and their respective triggers for your content. To hide this panel in sidebar, give it the name: hidden, in the Template Properties, sidebar_tab_title',
46 | 'properties' =>
47 | array (
48 | ),
49 | ), '', true, true);
50 | $chunks[2]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_structures.chunk.html'));
51 |
52 | $chunks[3] = $modx->newObject('modChunk');
53 | $chunks[3]->fromArray(array (
54 | 'id' => 3,
55 | 'property_preprocess' => false,
56 | 'name' => 'st.lector_importMarker_tpl',
57 | 'description' => 'Structures uses this template to break content into blocks/structures. Existing Content must have MODX comment tag [[-TB-MARKER]] to use the import tool or to use Manager resource url this parameter &autoImport',
58 | 'properties' =>
59 | array (
60 | ),
61 | ), '', true, true);
62 | $chunks[3]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_importmarker_tpl.chunk.html'));
63 |
64 | return $chunks;
65 |
--------------------------------------------------------------------------------
/_build/data/mgr/transport.chunks.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $chunks */
24 |
25 |
26 | $chunks = array();
27 |
28 | $chunks[1] = $modx->newObject('modChunk');
29 | $chunks[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'st.lector_snippets_base',
33 | 'description' => 'If you are not using pureContent, then you\'ll need to wrap your content with any markup. Classname tb-wrapper-tlb must be applied to the top-level-block; and tb-tiny-md or whatever you have setup in your editor chunk: st.lector_tinymce_config',
34 | 'properties' =>
35 | array (
36 | ),
37 | ), '', true, true);
38 | $chunks[1]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_snippets_base.chunk.html'));
39 |
40 | $chunks[2] = $modx->newObject('modChunk');
41 | $chunks[2]->fromArray(array (
42 | 'id' => 2,
43 | 'property_preprocess' => false,
44 | 'name' => 'st.ace_mirror_config',
45 | 'description' => 'Editor settings for Ace or CodeMirror(coming soon)',
46 | 'properties' =>
47 | array (
48 | ),
49 | ), '', true, true);
50 | $chunks[2]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.ace_mirror_config.chunk.html'));
51 |
52 | $chunks[3] = $modx->newObject('modChunk');
53 | $chunks[3]->fromArray(array (
54 | 'id' => 3,
55 | 'property_preprocess' => false,
56 | 'name' => 'st.help_howto',
57 | 'description' => 'Info that goes into modal triggered by Structures Help button',
58 | 'properties' =>
59 | array (
60 | ),
61 | ), '', true, true);
62 | $chunks[3]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.help_howto.chunk.html'));
63 |
64 | $chunks[4] = $modx->newObject('modChunk');
65 | $chunks[4]->fromArray(array (
66 | 'id' => 4,
67 | 'property_preprocess' => false,
68 | 'name' => 'st.lector_importWrapper_tpl',
69 | 'description' => 'Template used by Structures to wrap content that has MODX comment tag, [[-TB-MARKER]]. Use the import tool or use Manager resource url parameter &autoImport. This chunk is sample using the Markdown block/structure.',
70 | 'properties' =>
71 | array (
72 | ),
73 | ), '', true, true);
74 | $chunks[4]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_importwrapper_tpl.chunk.html'));
75 |
76 | $chunks[5] = $modx->newObject('modChunk');
77 | $chunks[5]->fromArray(array (
78 | 'id' => 5,
79 | 'property_preprocess' => false,
80 | 'name' => 'st.lector_snippets_launcher',
81 | 'description' => 'Tree buttons used to insert new blocks/structures into your content from st.lector_snippets_base',
82 | 'properties' =>
83 | array (
84 | ),
85 | ), '', true, true);
86 | $chunks[5]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_snippets_launcher.chunk.html'));
87 |
88 | $chunks[6] = $modx->newObject('modChunk');
89 | $chunks[6]->fromArray(array (
90 | 'id' => 6,
91 | 'property_preprocess' => false,
92 | 'name' => 'st.lector_importMarker_tpl',
93 | 'description' => 'Structures uses this template to break content into blocks/structures. Existing Content must have MODX comment tag [[-TB-MARKER]] to use the import tool or to use Manager resource url this parameter &autoImport',
94 | 'properties' =>
95 | array (
96 | ),
97 | ), '', true, true);
98 | $chunks[6]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.lector_importmarker_tpl.chunk.html'));
99 |
100 | $chunks[7] = $modx->newObject('modChunk');
101 | $chunks[7]->fromArray(array (
102 | 'id' => 7,
103 | 'property_preprocess' => false,
104 | 'name' => 'st.tinymce_config',
105 | 'description' => 'Editor settings: Without this chunk no editing is possible.',
106 | 'properties' =>
107 | array (
108 | ),
109 | ), '', true, true);
110 | $chunks[7]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.tinymce_config.chunk.html'));
111 |
112 | $chunks[8] = $modx->newObject('modChunk');
113 | $chunks[8]->fromArray(array (
114 | 'id' => 8,
115 | 'property_preprocess' => false,
116 | 'name' => 'st.wrapper_tpl',
117 | 'description' => 'Wrapper to set the environment of Structures in the Manager',
118 | 'properties' =>
119 | array (
120 | ),
121 | ), '', true, true);
122 | $chunks[8]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.wrapper_tpl.chunk.html'));
123 |
124 | $chunks[9] = $modx->newObject('modChunk');
125 | $chunks[9]->fromArray(array (
126 | 'id' => 9,
127 | 'property_preprocess' => false,
128 | 'name' => 'st.slate_snippets_launcher',
129 | 'description' => 'Tree buttons used to insert new blocks/structures into your content from st.snippets_base',
130 | 'properties' =>
131 | array (
132 | ),
133 | ), '', true, true);
134 | $chunks[9]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_snippets_launcher.chunk.html'));
135 |
136 | $chunks[10] = $modx->newObject('modChunk');
137 | $chunks[10]->fromArray(array (
138 | 'id' => 10,
139 | 'property_preprocess' => false,
140 | 'name' => 'st.save_buttons',
141 | 'description' => 'Buttons that appear next to MODX Save/Duplicate buttons',
142 | 'properties' =>
143 | array (
144 | ),
145 | ), '', true, true);
146 | $chunks[10]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.save_buttons.chunk.html'));
147 |
148 | $chunks[11] = $modx->newObject('modChunk');
149 | $chunks[11]->fromArray(array (
150 | 'id' => 11,
151 | 'property_preprocess' => false,
152 | 'name' => 'st.slate_snippets_base',
153 | 'description' => 'If you are not using pureContent, then you\'ll need to wrap your content with any markup. Classname tb-wrapper-tlb must be applied to the top-level-block; and tb-tiny-md or whatever you have setup in your editor chunk: st.tinymce_config',
154 | 'properties' =>
155 | array (
156 | ),
157 | ), '', true, true);
158 | $chunks[11]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_snippets_base.chunk.html'));
159 |
160 | $chunks[12] = $modx->newObject('modChunk');
161 | $chunks[12]->fromArray(array (
162 | 'id' => 12,
163 | 'property_preprocess' => false,
164 | 'name' => 'st.slate_importWrapper_tpl',
165 | 'description' => 'Template used by Structures to wrap content that has MODX comment tag, [[-TB-MARKER]]. Use the import tool or use Manager resource url parameter &autoImport. This chunk is sample using the Markdown block/structure.',
166 | 'properties' =>
167 | array (
168 | ),
169 | ), '', true, true);
170 | $chunks[12]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_importwrapper_tpl.chunk.html'));
171 |
172 | $chunks[13] = $modx->newObject('modChunk');
173 | $chunks[13]->fromArray(array (
174 | 'id' => 13,
175 | 'property_preprocess' => false,
176 | 'name' => 'st.slate_importMarker_tpl',
177 | 'description' => 'Structures uses this template to break content into blocks/structures. Existing Content must have MODX comment tag [[-TB-MARKER]] to use the import tool or to use Manager resource url this parameter &autoImport',
178 | 'properties' =>
179 | array (
180 | ),
181 | ), '', true, true);
182 | $chunks[13]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_importmarker_tpl.chunk.html'));
183 |
184 | return $chunks;
185 |
--------------------------------------------------------------------------------
/_build/data/properties/properties.structures-lector.template.php:
--------------------------------------------------------------------------------
1 |
17 | array (
18 | 'name' => 'customPset',
19 | 'desc' => 'Takes DEFAULT or name of a PropertySet. A template namesake pset is automatically used, or else DEFAULT will ignite the default properties of current Template. This setting is ONLY useful when set in Template Default Properties - NOT Custom Property Set Properties. ',
20 | 'type' => 'textfield',
21 | 'options' =>
22 | array (
23 | ),
24 | 'value' => 'default',
25 | 'lexicon' => NULL,
26 | 'area' => '0. Main',
27 | ),
28 | 'showDebugInfo' =>
29 | array (
30 | 'name' => 'showDebugInfo',
31 | 'desc' => 'Display a detailed log of Structure Settings in the sidebar of the Manager Resource',
32 | 'type' => 'combo-boolean',
33 | 'options' =>
34 | array (
35 | ),
36 | 'value' => true,
37 | 'lexicon' => NULL,
38 | 'area' => '0. Main',
39 | ),
40 | 'autoImport' =>
41 | array (
42 | 'name' => 'autoImport',
43 | 'desc' => 'EXPERIMENTAL: your existing content (no need for [[-TB-MARKER]] or [[-TB-MARKER-SINGLE]] placeholders, will be structured according to your importWrapper and importMarker chunks. Please turn this OFF when you are done auto importing.',
44 | 'type' => 'combo-boolean',
45 | 'options' =>
46 | array (
47 | ),
48 | 'value' => false,
49 | 'lexicon' => NULL,
50 | 'area' => '1. Advanced and Experimental',
51 | ),
52 | 'autoImportDemandMarkers' =>
53 | array (
54 | 'name' => 'autoImportDemandMarkers',
55 | 'desc' => 'EXPERIMENTAL: content will not be imported/converted without it containing at least [[-TB-MARKER]] or [[-TB-MARKER-SINGLE]]',
56 | 'type' => 'combo-boolean',
57 | 'options' =>
58 | array (
59 | ),
60 | 'value' => true,
61 | 'lexicon' => NULL,
62 | 'area' => '1. Advanced and Experimental',
63 | ),
64 | 'autoImportSave' =>
65 | array (
66 | 'name' => 'autoImportSave',
67 | 'desc' => 'EXPERIMENTAL: autoImport will save the resource when it is done. Please turn this OFF IMMEDIATELY you are done auto importing.',
68 | 'type' => 'combo-boolean',
69 | 'options' =>
70 | array (
71 | ),
72 | 'value' => false,
73 | 'lexicon' => NULL,
74 | 'area' => '1. Advanced and Experimental',
75 | ),
76 | 'pureContent' =>
77 | array (
78 | 'name' => 'pureContent',
79 | 'desc' => 'Use Pure Content mode if your content is either pure Markdown(which includes HTML) or pure Rich Text(excluding MD). Your content WILL NOT be wrapped at all by any markup. [[-TB-MARKER]] will be inserted in the case of multiple structures.',
80 | 'type' => 'list',
81 | 'options' =>
82 | array (
83 | 0 =>
84 | array (
85 | 'text' => 'Rich Text (fc: full content)',
86 | 'value' => 'fc',
87 | 'name' => 'Rich Text (fc: full content)',
88 | ),
89 | 1 =>
90 | array (
91 | 'text' => 'Markdown(md)',
92 | 'value' => 'md',
93 | 'name' => 'Markdown(md)',
94 | ),
95 | 2 =>
96 | array (
97 | 'text' => 'Syntax Highlighted MD Code (rc: raw code)',
98 | 'value' => 'rc',
99 | 'name' => 'Syntax Highlighted MD Code (rc: raw code)',
100 | ),
101 | 3 =>
102 | array (
103 | 'text' => 'Disabled',
104 | 'value' => '',
105 | 'name' => 'Disabled',
106 | ),
107 | ),
108 | 'value' => '',
109 | 'lexicon' => NULL,
110 | 'area' => '1. Advanced and Experimental',
111 | ),
112 | 'ace_mirror_init_chunk' =>
113 | array (
114 | 'name' => 'ace_mirror_init_chunk',
115 | 'desc' => 'Chunk to run CE (Code Editor)',
116 | 'type' => 'textfield',
117 | 'options' =>
118 | array (
119 | ),
120 | 'value' => 'st.ace_mirror_config',
121 | 'lexicon' => NULL,
122 | 'area' => '2. Manager Chunks Used by Template',
123 | ),
124 | 'all_structures_chunk' =>
125 | array (
126 | 'name' => 'all_structures_chunk',
127 | 'desc' => 'Store all your predefined structures (blocks / HTML snippets)',
128 | 'type' => 'textfield',
129 | 'options' =>
130 | array (
131 | ),
132 | 'value' => 'st.lector_structures',
133 | 'lexicon' => NULL,
134 | 'area' => '2. Manager Chunks Used by Template',
135 | ),
136 | 'content_wrapper_chunk' =>
137 | array (
138 | 'name' => 'content_wrapper_chunk',
139 | 'desc' => 'Wrapper tpl chunk for displaying resource content. Necessary placeholders: +tinyBlocksMainWrapperId, +tinyBlocksRowsWrapperClass, +content',
140 | 'type' => 'textfield',
141 | 'options' =>
142 | array (
143 | ),
144 | 'value' => 'st.wrapper_tpl',
145 | 'lexicon' => NULL,
146 | 'area' => '2. Manager Chunks Used by Template',
147 | ),
148 | 'help_howto' =>
149 | array (
150 | 'name' => 'help_howto',
151 | 'desc' => 'Some help goes far.',
152 | 'type' => 'textfield',
153 | 'options' =>
154 | array (
155 | ),
156 | 'value' => 'st.help_howto',
157 | 'lexicon' => NULL,
158 | 'area' => '2. Manager Chunks Used by Template',
159 | ),
160 | 'import_marker_chunk' =>
161 | array (
162 | 'name' => 'import_marker_chunk',
163 | 'desc' => 'To import existing content into Structures simply add this parameter to your resource url: &autoImport. import_marker_chunk will replace this MODX comment tag [[-TB-MARKER]] in your content. Please see your block_reel_chunk (st.snippets_base) for HTML guide',
164 | 'type' => 'textfield',
165 | 'options' =>
166 | array (
167 | ),
168 | 'value' => 'st.lector_importMarker_tpl',
169 | 'lexicon' => NULL,
170 | 'area' => '2. Manager Chunks Used by Template',
171 | ),
172 | 'import_wrapper_chunk' =>
173 | array (
174 | 'name' => 'import_wrapper_chunk',
175 | 'desc' => 'To import existing content, simply add to the resource manager url this parameter &autoImport',
176 | 'type' => 'textfield',
177 | 'options' =>
178 | array (
179 | ),
180 | 'value' => 'st.lector_importWrapper_tpl',
181 | 'lexicon' => NULL,
182 | 'area' => '2. Manager Chunks Used by Template',
183 | ),
184 | 'manager_misc_buttons_chunk' =>
185 | array (
186 | 'name' => 'manager_misc_buttons_chunk',
187 | 'desc' => 'Add or remove buttons next to Manager save button. Richtext, Markdown and Code Editors...',
188 | 'type' => 'textfield',
189 | 'options' =>
190 | array (
191 | ),
192 | 'value' => 'st.save_buttons',
193 | 'lexicon' => NULL,
194 | 'area' => '2. Manager Chunks Used by Template',
195 | ),
196 | 'tinymce_init_chunk' =>
197 | array (
198 | 'name' => 'tinymce_init_chunk',
199 | 'desc' => 'Without this chunk NOTHING is editable. TinyMCE powerful API caters for all the sorts of editors used by tinyBlocks.js',
200 | 'type' => 'textfield',
201 | 'options' =>
202 | array (
203 | ),
204 | 'value' => 'st.tinymce_config',
205 | 'lexicon' => NULL,
206 | 'area' => '2. Manager Chunks Used by Template',
207 | ),
208 | 'content_tab_title' =>
209 | array (
210 | 'name' => 'content_tab_title',
211 | 'desc' => 'The tab title for resource content area',
212 | 'type' => 'textfield',
213 | 'options' =>
214 | array (
215 | ),
216 | 'value' => 'Content',
217 | 'lexicon' => NULL,
218 | 'area' => '3. Tab Text',
219 | ),
220 | 'sidebar_tab_title' =>
221 | array (
222 | 'name' => 'sidebar_tab_title',
223 | 'desc' => 'The sidebar tab title - which will be first in line. To hide this panel set the name to: hidden ',
224 | 'type' => 'textfield',
225 | 'options' =>
226 | array (
227 | ),
228 | 'value' => 'Structures',
229 | 'lexicon' => NULL,
230 | 'area' => '3. Tab Text',
231 | ),
232 | 'CDN_Ace' =>
233 | array (
234 | 'name' => 'CDN_Ace',
235 | 'desc' => 'Leave empty to disable Syntax Highlighter Editor (Ace)....Default: https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
236 | 'type' => 'textfield',
237 | 'options' =>
238 | array (
239 | ),
240 | 'value' => 'https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
241 | 'lexicon' => NULL,
242 | 'area' => '4. Structures File Urls',
243 | ),
244 | 'manager_css_function_file' =>
245 | array (
246 | 'name' => 'manager_css_function_file',
247 | 'desc' => 'This CSS file is necessary for fundamental functionality. Designed by treigh!',
248 | 'type' => 'textfield',
249 | 'options' =>
250 | array (
251 | ),
252 | 'value' => '[[++assets_url]]components/structures/css/mgr.css',
253 | 'lexicon' => NULL,
254 | 'area' => '4. Structures File Urls',
255 | ),
256 | 'manager_css_override_file' =>
257 | array (
258 | 'name' => 'manager_css_override_file',
259 | 'desc' => 'Use this to override anything you want.',
260 | 'type' => 'textfield',
261 | 'options' =>
262 | array (
263 | ),
264 | 'value' => '[[++assets_url]]components/structures/css/mgr.override.css',
265 | 'lexicon' => NULL,
266 | 'area' => '4. Structures File Urls',
267 | ),
268 | 'manager_css_richtext' =>
269 | array (
270 | 'name' => 'manager_css_richtext',
271 | 'desc' => 'Enclose your frontend CSS properly so that you see/preview exactly as your site, as you edit in the Rich Text Structure.',
272 | 'type' => 'textfield',
273 | 'options' =>
274 | array (
275 | ),
276 | 'value' => '[[++assets_url]]components/structures/css/mgr.richtext.css',
277 | 'lexicon' => NULL,
278 | 'area' => '4. Structures File Urls',
279 | ),
280 | 'tinyblocks_js_file' =>
281 | array (
282 | 'name' => 'tinyblocks_js_file',
283 | 'desc' => 'Powered by tinyBlocks.js!',
284 | 'type' => 'textfield',
285 | 'options' =>
286 | array (
287 | ),
288 | 'value' => '[[++assets_url]]components/structures/js/tinyBlocks.js',
289 | 'lexicon' => NULL,
290 | 'area' => '4. Structures File Urls',
291 | ),
292 | 'tinymce_donshakepeare_plugins_file' =>
293 | array (
294 | 'name' => 'tinymce_donshakepeare_plugins_file',
295 | 'desc' => 'A compressed and preloaded pack of donshakepeare-beautifully-handcrafted TinyMCE plugins. No need to call said plugins in TinyMCE init.',
296 | 'type' => 'textfield',
297 | 'options' =>
298 | array (
299 | ),
300 | 'value' => '[[++assets_url]]components/structures/js/tinymce_plugins.min.js',
301 | 'lexicon' => NULL,
302 | 'area' => '4. Structures File Urls',
303 | ),
304 | 'duplicateBlockClass' =>
305 | array (
306 | 'name' => 'duplicateBlockClass',
307 | 'desc' => 'Class to style duplicated row',
308 | 'type' => 'textfield',
309 | 'options' =>
310 | array (
311 | ),
312 | 'value' => 'st-duplicate',
313 | 'lexicon' => NULL,
314 | 'area' => '5. Class names used in mgr CSS file',
315 | ),
316 | 'hiddenBlockClass' =>
317 | array (
318 | 'name' => 'hiddenBlockClass',
319 | 'desc' => 'Used to style and hide Blocks',
320 | 'type' => 'textfield',
321 | 'options' =>
322 | array (
323 | ),
324 | 'value' => 'st-hidden',
325 | 'lexicon' => NULL,
326 | 'area' => '5. Class names used in mgr CSS file',
327 | ),
328 | 'minBlockClass' =>
329 | array (
330 | 'name' => 'minBlockClass',
331 | 'desc' => 'EXPERIMENTAL: Used for sub inset blocks',
332 | 'type' => 'textfield',
333 | 'options' =>
334 | array (
335 | ),
336 | 'value' => 'st-shrink',
337 | 'lexicon' => NULL,
338 | 'area' => '5. Class names used in mgr CSS file',
339 | ),
340 | 'newBlockClass' =>
341 | array (
342 | 'name' => 'newBlockClass',
343 | 'desc' => 'Used to style newly added Blocks',
344 | 'type' => 'textfield',
345 | 'options' =>
346 | array (
347 | ),
348 | 'value' => 'st-new-block',
349 | 'lexicon' => NULL,
350 | 'area' => '5. Class names used in mgr CSS file',
351 | ),
352 | 'originalSourceId' =>
353 | array (
354 | 'name' => 'originalSourceId',
355 | 'desc' => 'Use this to specify the origin of content feed. Must be the content of a live Textarea. For now, only content field (textarea#ta) of MODX Manager resource is supported.',
356 | 'type' => 'textfield',
357 | 'options' =>
358 | array (
359 | ),
360 | 'value' => 'ta',
361 | 'lexicon' => NULL,
362 | 'area' => '5. Class names used in mgr CSS file',
363 | ),
364 | 'rowClass' =>
365 | array (
366 | 'name' => 'rowClass',
367 | 'desc' => 'If you want to style Stuctures\' Rows, add your own class. Rows are the top level elements in your blocks_reel_chunk markup.',
368 | 'type' => 'textfield',
369 | 'options' =>
370 | array (
371 | ),
372 | 'value' => 'st-row',
373 | 'lexicon' => NULL,
374 | 'area' => '5. Class names used in mgr CSS file',
375 | ),
376 | 'rowTempHolderClass' =>
377 | array (
378 | 'name' => 'rowTempHolderClass',
379 | 'desc' => 'Each Block/Row will be wrapped with div.tinyBlocksRowTempHolderClass. Add classes if you want.',
380 | 'type' => 'textfield',
381 | 'options' =>
382 | array (
383 | ),
384 | 'value' => 'st-outer',
385 | 'lexicon' => NULL,
386 | 'area' => '5. Class names used in mgr CSS file',
387 | ),
388 | 'rowsWrapperClass' =>
389 | array (
390 | 'name' => 'rowsWrapperClass',
391 | 'desc' => 'Used to identify the container of all the main structure/blocks/rows',
392 | 'type' => 'textfield',
393 | 'options' =>
394 | array (
395 | ),
396 | 'value' => 'st-container-fluid',
397 | 'lexicon' => NULL,
398 | 'area' => '5. Class names used in mgr CSS file',
399 | ),
400 | 'shrinkClass' =>
401 | array (
402 | 'name' => 'shrinkClass',
403 | 'desc' => 'When a Block is dragged/duplicated or before-inserted, all Blocks are immediately shrunk. Add class to style shrinkage.',
404 | 'type' => 'textfield',
405 | 'options' =>
406 | array (
407 | ),
408 | 'value' => 'st-shrink',
409 | 'lexicon' => NULL,
410 | 'area' => '5. Class names used in mgr CSS file',
411 | ),
412 | );
413 |
414 | return $properties;
415 |
416 |
--------------------------------------------------------------------------------
/_build/data/properties/properties.structures-slate.template.php:
--------------------------------------------------------------------------------
1 |
17 | array (
18 | 'name' => 'customPset',
19 | 'desc' => 'Takes DEFAULT or name of a PropertySet. A template namesake pset is automatically used, or else DEFAULT will ignite the default properties of current Template. This setting is ONLY useful when set in Template Default Properties - NOT Custom Property Set Properties. ',
20 | 'type' => 'textfield',
21 | 'options' =>
22 | array (
23 | ),
24 | 'value' => 'default',
25 | 'lexicon' => NULL,
26 | 'area' => '0. Main',
27 | ),
28 | 'showDebugInfo' =>
29 | array (
30 | 'name' => 'showDebugInfo',
31 | 'desc' => 'Display a detailed log of Structure Settings in the sidebar of the Manager Resource',
32 | 'type' => 'combo-boolean',
33 | 'options' =>
34 | array (
35 | ),
36 | 'value' => true,
37 | 'lexicon' => NULL,
38 | 'area' => '0. Main',
39 | ),
40 | 'autoImport' =>
41 | array (
42 | 'name' => 'autoImport',
43 | 'desc' => 'EXPERIMENTAL: your existing content (no need for [[-TB-MARKER]] or [[-TB-MARKER-SINGLE]] placeholders, will be structured according to your importWrapper and importMarker chunks. Please turn this OFF when you are done auto importing.',
44 | 'type' => 'combo-boolean',
45 | 'options' =>
46 | array (
47 | ),
48 | 'value' => false,
49 | 'lexicon' => NULL,
50 | 'area' => '1. Advanced and Experimental',
51 | ),
52 | 'autoImportDemandMarkers' =>
53 | array (
54 | 'name' => 'autoImportDemandMarkers',
55 | 'desc' => 'EXPERIMENTAL: content will not be imported/converted without it containing at least [[-TB-MARKER]] or [[-TB-MARKER-SINGLE]]',
56 | 'type' => 'combo-boolean',
57 | 'options' =>
58 | array (
59 | ),
60 | 'value' => true,
61 | 'lexicon' => NULL,
62 | 'area' => '1. Advanced and Experimental',
63 | ),
64 | 'autoImportSave' =>
65 | array (
66 | 'name' => 'autoImportSave',
67 | 'desc' => 'EXPERIMENTAL: autoImport will save the resource when it is done. Please turn this OFF IMMEDIATELY you are done auto importing.',
68 | 'type' => 'combo-boolean',
69 | 'options' =>
70 | array (
71 | ),
72 | 'value' => false,
73 | 'lexicon' => NULL,
74 | 'area' => '1. Advanced and Experimental',
75 | ),
76 | 'pureContent' =>
77 | array (
78 | 'name' => 'pureContent',
79 | 'desc' => 'Use Pure Content mode if your content is either pure Markdown(which includes HTML) or pure Rich Text(excluding MD). Your content WILL NOT be wrapped at all by any markup. [[-TB-MARKER]] will be inserted in the case of multiple structures.',
80 | 'type' => 'list',
81 | 'options' =>
82 | array (
83 | 0 =>
84 | array (
85 | 'text' => 'Rich Text (fc: full content)',
86 | 'value' => 'fc',
87 | 'name' => 'Rich Text (fc: full content)',
88 | ),
89 | 1 =>
90 | array (
91 | 'text' => 'Markdown(md)',
92 | 'value' => 'md',
93 | 'name' => 'Markdown(md)',
94 | ),
95 | 2 =>
96 | array (
97 | 'text' => 'Syntax Highlighted MD Code (rc: raw code)',
98 | 'value' => 'rc',
99 | 'name' => 'Syntax Highlighted MD Code (rc: raw code)',
100 | ),
101 | 3 =>
102 | array (
103 | 'text' => 'Disabled',
104 | 'value' => '',
105 | 'name' => 'Disabled',
106 | ),
107 | ),
108 | 'value' => '',
109 | 'lexicon' => NULL,
110 | 'area' => '1. Advanced and Experimental',
111 | ),
112 | 'ace_mirror_init_chunk' =>
113 | array (
114 | 'name' => 'ace_mirror_init_chunk',
115 | 'desc' => 'Chunk to run CE (Code Editor)',
116 | 'type' => 'textfield',
117 | 'options' =>
118 | array (
119 | ),
120 | 'value' => 'st.ace_mirror_config',
121 | 'lexicon' => NULL,
122 | 'area' => '2. Manager Chunks Used by Template',
123 | ),
124 | 'all_structures_chunk' =>
125 | array (
126 | 'name' => 'all_structures_chunk',
127 | 'desc' => 'Store all your predefined structures (blocks / HTML snippets)',
128 | 'type' => 'textfield',
129 | 'options' =>
130 | array (
131 | ),
132 | 'value' => 'st.slate_structures',
133 | 'lexicon' => NULL,
134 | 'area' => '2. Manager Chunks Used by Template',
135 | ),
136 | 'content_wrapper_chunk' =>
137 | array (
138 | 'name' => 'content_wrapper_chunk',
139 | 'desc' => 'Wrapper tpl chunk for displaying resource content. Necessary placeholders: +tinyBlocksMainWrapperId, +tinyBlocksRowsWrapperClass, +content',
140 | 'type' => 'textfield',
141 | 'options' =>
142 | array (
143 | ),
144 | 'value' => 'st.wrapper_tpl',
145 | 'lexicon' => NULL,
146 | 'area' => '2. Manager Chunks Used by Template',
147 | ),
148 | 'help_howto' =>
149 | array (
150 | 'name' => 'help_howto',
151 | 'desc' => 'Some help goes far.',
152 | 'type' => 'textfield',
153 | 'options' =>
154 | array (
155 | ),
156 | 'value' => 'st.help_howto',
157 | 'lexicon' => NULL,
158 | 'area' => '2. Manager Chunks Used by Template',
159 | ),
160 | 'import_marker_chunk' =>
161 | array (
162 | 'name' => 'import_marker_chunk',
163 | 'desc' => 'To import existing content into Structures simply add this parameter to your resource url: &autoImport. import_marker_chunk will replace this MODX comment tag [[-TB-MARKER]] in your content. Please see your block_reel_chunk (st.snippets_base) for HTML guide',
164 | 'type' => 'textfield',
165 | 'options' =>
166 | array (
167 | ),
168 | 'value' => 'st.slate_importMarker_tpl',
169 | 'lexicon' => NULL,
170 | 'area' => '2. Manager Chunks Used by Template',
171 | ),
172 | 'import_wrapper_chunk' =>
173 | array (
174 | 'name' => 'import_wrapper_chunk',
175 | 'desc' => 'To import existing content, simply add to the resource manager url this parameter &autoImport',
176 | 'type' => 'textfield',
177 | 'options' =>
178 | array (
179 | ),
180 | 'value' => 'st.slate_importWrapper_tpl',
181 | 'lexicon' => NULL,
182 | 'area' => '2. Manager Chunks Used by Template',
183 | ),
184 | 'manager_misc_buttons_chunk' =>
185 | array (
186 | 'name' => 'manager_misc_buttons_chunk',
187 | 'desc' => 'Add or remove buttons next to Manager save button. Richtext, Markdown and Code Editors...',
188 | 'type' => 'textfield',
189 | 'options' =>
190 | array (
191 | ),
192 | 'value' => 'st.save_buttons',
193 | 'lexicon' => NULL,
194 | 'area' => '2. Manager Chunks Used by Template',
195 | ),
196 | 'tinymce_init_chunk' =>
197 | array (
198 | 'name' => 'tinymce_init_chunk',
199 | 'desc' => 'Without this chunk NOTHING is editable. TinyMCE powerful API caters for all the sorts of editors used by tinyBlocks.js',
200 | 'type' => 'textfield',
201 | 'options' =>
202 | array (
203 | ),
204 | 'value' => 'st.tinymce_config',
205 | 'lexicon' => NULL,
206 | 'area' => '2. Manager Chunks Used by Template',
207 | ),
208 | 'content_tab_title' =>
209 | array (
210 | 'name' => 'content_tab_title',
211 | 'desc' => 'The tab title for resource content area',
212 | 'type' => 'textfield',
213 | 'options' =>
214 | array (
215 | ),
216 | 'value' => 'Content',
217 | 'lexicon' => NULL,
218 | 'area' => '3. Tab Text',
219 | ),
220 | 'sidebar_tab_title' =>
221 | array (
222 | 'name' => 'sidebar_tab_title',
223 | 'desc' => 'The sidebar tab title - which will be first in line. To hide this panel set the name to: hidden ',
224 | 'type' => 'textfield',
225 | 'options' =>
226 | array (
227 | ),
228 | 'value' => 'Structures',
229 | 'lexicon' => NULL,
230 | 'area' => '3. Tab Text',
231 | ),
232 | 'CDN_Ace' =>
233 | array (
234 | 'name' => 'CDN_Ace',
235 | 'desc' => 'Leave empty to disable Syntax Highlighter Editor (Ace)....Default: https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
236 | 'type' => 'textfield',
237 | 'options' =>
238 | array (
239 | ),
240 | 'value' => 'https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
241 | 'lexicon' => NULL,
242 | 'area' => '4. Structures File Urls',
243 | ),
244 | 'manager_css_function_file' =>
245 | array (
246 | 'name' => 'manager_css_function_file',
247 | 'desc' => 'This CSS file is necessary for fundamental functionality. Designed by treigh!',
248 | 'type' => 'textfield',
249 | 'options' =>
250 | array (
251 | ),
252 | 'value' => '[[++assets_url]]components/structures/css/mgr.css',
253 | 'lexicon' => NULL,
254 | 'area' => '4. Structures File Urls',
255 | ),
256 | 'manager_css_override_file' =>
257 | array (
258 | 'name' => 'manager_css_override_file',
259 | 'desc' => 'Use this to override anything you want.',
260 | 'type' => 'textfield',
261 | 'options' =>
262 | array (
263 | ),
264 | 'value' => '[[++assets_url]]components/structures/css/mgr.override.css',
265 | 'lexicon' => NULL,
266 | 'area' => '4. Structures File Urls',
267 | ),
268 | 'manager_css_richtext' =>
269 | array (
270 | 'name' => 'manager_css_richtext',
271 | 'desc' => 'Enclose your frontend CSS properly so that you see/preview exactly as your site, as you edit in the Rich Text Structure.',
272 | 'type' => 'textfield',
273 | 'options' =>
274 | array (
275 | ),
276 | 'value' => '[[++assets_url]]components/structures/css/mgr.richtext.css',
277 | 'lexicon' => NULL,
278 | 'area' => '4. Structures File Urls',
279 | ),
280 | 'tinyblocks_js_file' =>
281 | array (
282 | 'name' => 'tinyblocks_js_file',
283 | 'desc' => 'Powered by tinyBlocks.js!',
284 | 'type' => 'textfield',
285 | 'options' =>
286 | array (
287 | ),
288 | 'value' => '[[++assets_url]]components/structures/js/tinyBlocks.js',
289 | 'lexicon' => NULL,
290 | 'area' => '4. Structures File Urls',
291 | ),
292 | 'tinymce_donshakepeare_plugins_file' =>
293 | array (
294 | 'name' => 'tinymce_donshakepeare_plugins_file',
295 | 'desc' => 'A compressed and preloaded pack of donshakepeare-beautifully-handcrafted TinyMCE plugins. No need to call said plugins in TinyMCE init.',
296 | 'type' => 'textfield',
297 | 'options' =>
298 | array (
299 | ),
300 | 'value' => '[[++assets_url]]components/structures/js/tinymce_plugins.min.js',
301 | 'lexicon' => NULL,
302 | 'area' => '4. Structures File Urls',
303 | ),
304 | 'duplicateBlockClass' =>
305 | array (
306 | 'name' => 'duplicateBlockClass',
307 | 'desc' => 'Class to style duplicated row',
308 | 'type' => 'textfield',
309 | 'options' =>
310 | array (
311 | ),
312 | 'value' => 'st-duplicate',
313 | 'lexicon' => NULL,
314 | 'area' => '5. Class names used in mgr CSS file',
315 | ),
316 | 'hiddenBlockClass' =>
317 | array (
318 | 'name' => 'hiddenBlockClass',
319 | 'desc' => 'Used to style and hide Blocks',
320 | 'type' => 'textfield',
321 | 'options' =>
322 | array (
323 | ),
324 | 'value' => 'st-hidden',
325 | 'lexicon' => NULL,
326 | 'area' => '5. Class names used in mgr CSS file',
327 | ),
328 | 'minBlockClass' =>
329 | array (
330 | 'name' => 'minBlockClass',
331 | 'desc' => 'EXPERIMENTAL: Used for sub inset blocks',
332 | 'type' => 'textfield',
333 | 'options' =>
334 | array (
335 | ),
336 | 'value' => 'st-shrink',
337 | 'lexicon' => NULL,
338 | 'area' => '5. Class names used in mgr CSS file',
339 | ),
340 | 'newBlockClass' =>
341 | array (
342 | 'name' => 'newBlockClass',
343 | 'desc' => 'Used to style newly added Blocks',
344 | 'type' => 'textfield',
345 | 'options' =>
346 | array (
347 | ),
348 | 'value' => 'st-new-block',
349 | 'lexicon' => NULL,
350 | 'area' => '5. Class names used in mgr CSS file',
351 | ),
352 | 'originalSourceId' =>
353 | array (
354 | 'name' => 'originalSourceId',
355 | 'desc' => 'Use this to specify the origin of content feed. Must be the content of a live Textarea. For now, only content field (textarea#ta) of MODX Manager resource is supported.',
356 | 'type' => 'textfield',
357 | 'options' =>
358 | array (
359 | ),
360 | 'value' => 'ta',
361 | 'lexicon' => NULL,
362 | 'area' => '5. Class names used in mgr CSS file',
363 | ),
364 | 'rowClass' =>
365 | array (
366 | 'name' => 'rowClass',
367 | 'desc' => 'If you want to style Stuctures\' Rows, add your own class. Rows are the top level elements in your blocks_reel_chunk markup.',
368 | 'type' => 'textfield',
369 | 'options' =>
370 | array (
371 | ),
372 | 'value' => 'st-row',
373 | 'lexicon' => NULL,
374 | 'area' => '5. Class names used in mgr CSS file',
375 | ),
376 | 'rowTempHolderClass' =>
377 | array (
378 | 'name' => 'rowTempHolderClass',
379 | 'desc' => 'Each Block/Row will be wrapped with div.tinyBlocksRowTempHolderClass. Add classes if you want.',
380 | 'type' => 'textfield',
381 | 'options' =>
382 | array (
383 | ),
384 | 'value' => 'st-outer',
385 | 'lexicon' => NULL,
386 | 'area' => '5. Class names used in mgr CSS file',
387 | ),
388 | 'rowsWrapperClass' =>
389 | array (
390 | 'name' => 'rowsWrapperClass',
391 | 'desc' => 'Used to identify the container of all the main structure/blocks/rows',
392 | 'type' => 'textfield',
393 | 'options' =>
394 | array (
395 | ),
396 | 'value' => 'st-container-fluid',
397 | 'lexicon' => NULL,
398 | 'area' => '5. Class names used in mgr CSS file',
399 | ),
400 | 'shrinkClass' =>
401 | array (
402 | 'name' => 'shrinkClass',
403 | 'desc' => 'When a Block is dragged/duplicated or before-inserted, all Blocks are immediately shrunk. Add class to style shrinkage.',
404 | 'type' => 'textfield',
405 | 'options' =>
406 | array (
407 | ),
408 | 'value' => 'st-shrink',
409 | 'lexicon' => NULL,
410 | 'area' => '5. Class names used in mgr CSS file',
411 | ),
412 | );
413 |
414 | return $properties;
415 |
416 |
--------------------------------------------------------------------------------
/_build/data/properties/properties.structures.template.php:
--------------------------------------------------------------------------------
1 |
17 | array (
18 | 'name' => 'StructuresCustomPset',
19 | 'desc' => 'Takes the word: default (for Default Properties of Template). Or name of a PropertySet. Note: A PropertySet with same name as that of a Structures Template is automatically used. This setting is ONLY useful when set in Template Default Properties - NOT Custom Property Set Properties. Also, MODX tags in properties will not be parsed if using PSETS.',
20 | 'type' => 'textfield',
21 | 'options' =>
22 | array (
23 | ),
24 | 'value' => 'default',
25 | 'lexicon' => NULL,
26 | 'area' => '0. Main',
27 | ),
28 | 'standByStructure' =>
29 | array (
30 | 'name' => 'standByStructure',
31 | 'desc' => 'Structures will use any HTML value here to replace the st.help_howto chunk that fills Structures content area when empty ... e.g div class=tb-wrapper-tlb tb-tiny-fc data-tb-title=Default>start typing ... /div. Please enclose class names and other attrs with quotes',
32 | 'type' => 'textarea',
33 | 'options' =>
34 | array (
35 | ),
36 | 'value' => '',
37 | 'lexicon' => NULL,
38 | 'area' => '1. Advanced and Experimental',
39 | ),
40 | 'randomTips' =>
41 | array (
42 | 'name' => 'randomTips',
43 | 'desc' => 'Useful tips that appear/cycle at pageload. To disable, leave empty. Use || as delimiter.',
44 | 'type' => 'textarea',
45 | 'options' =>
46 | array (
47 | ),
48 | 'value' => '',
49 | 'lexicon' => NULL,
50 | 'area' => '1. Advanced and Experimental',
51 | ),
52 | 'pureContent' =>
53 | array (
54 | 'name' => 'pureContent',
55 | 'desc' => 'Use Pure Content mode if your content is either pure Markdown(which includes HTML) or pure Rich Text(excluding MD). Your content WILL NOT be wrapped at all by any markup. [[-STRUCTURES]] will be inserted in only the case of multiple structures. PureContent will not support Titles for Structures.',
56 | 'type' => 'list',
57 | 'options' =>
58 | array (
59 | 0 =>
60 | array (
61 | 'text' => 'Rich Text (fc: full content)',
62 | 'value' => 'fc',
63 | 'name' => 'Rich Text (fc: full content)',
64 | ),
65 | 1 =>
66 | array (
67 | 'text' => 'Markdown(md)',
68 | 'value' => 'md',
69 | 'name' => 'Markdown(md)',
70 | ),
71 | 2 =>
72 | array (
73 | 'text' => 'Syntax Highlighted MD Code (rc: raw code)',
74 | 'value' => 'rc',
75 | 'name' => 'Syntax Highlighted MD Code (rc: raw code)',
76 | ),
77 | 3 =>
78 | array (
79 | 'text' => 'Disabled',
80 | 'value' => '',
81 | 'name' => 'Disabled',
82 | ),
83 | ),
84 | 'value' => '',
85 | 'lexicon' => NULL,
86 | 'area' => '1. Advanced and Experimental',
87 | ),
88 | 'autoImportSave' =>
89 | array (
90 | 'name' => 'autoImportSave',
91 | 'desc' => 'EXPERIMENTAL: autoImport will save the resource when it is done. Please turn this OFF IMMEDIATELY you are done auto importing.',
92 | 'type' => 'combo-boolean',
93 | 'options' =>
94 | array (
95 | ),
96 | 'value' => false,
97 | 'lexicon' => NULL,
98 | 'area' => '1. Advanced and Experimental',
99 | ),
100 | 'autoImportDemandMarkers' =>
101 | array (
102 | 'name' => 'autoImportDemandMarkers',
103 | 'desc' => 'EXPERIMENTAL: content will not be imported/converted without it containing at least [[-STRUCTURES]] or [[-STRUCTURES-SINGLE]]',
104 | 'type' => 'combo-boolean',
105 | 'options' =>
106 | array (
107 | ),
108 | 'value' => true,
109 | 'lexicon' => NULL,
110 | 'area' => '1. Advanced and Experimental',
111 | ),
112 | 'autoImport' =>
113 | array (
114 | 'name' => 'autoImport',
115 | 'desc' => 'EXPERIMENTAL: your existing content (no need for [[-STRUCTURES]] or [[-STRUCTURES-SINGLE]] placeholders, will be structured according to your importWrapper and importMarker chunks. Please turn this OFF when you are done auto importing.',
116 | 'type' => 'combo-boolean',
117 | 'options' =>
118 | array (
119 | ),
120 | 'value' => false,
121 | 'lexicon' => NULL,
122 | 'area' => '1. Advanced and Experimental',
123 | ),
124 | 'structuresTV_ids' =>
125 | array (
126 | 'name' => 'structuresTV_ids',
127 | 'desc' => 'Comma-separated list of ids of TVs to bind to Structures. Two Modes: 1) 12,13,14,15 ... 2) 12*richtext, 13*markdown, 14*markdown, 15*richtext ... Supported TV xtypes: Textarea, Text, Hidden.',
128 | 'type' => 'textfield',
129 | 'options' =>
130 | array (
131 | ),
132 | 'value' => '',
133 | 'lexicon' => NULL,
134 | 'area' => '1. Advanced and Experimental TVS',
135 | ),
136 | 'defaultGalleryTVid' =>
137 | array (
138 | 'name' => 'defaultGalleryTVid',
139 | 'desc' => 'TV id for default Resource Gallery.',
140 | 'type' => 'numberfield',
141 | 'options' =>
142 | array (
143 | ),
144 | 'value' => '',
145 | 'lexicon' => NULL,
146 | 'area' => '1. Advanced and Experimental TVS',
147 | ),
148 | 'tinymce_init_chunk' =>
149 | array (
150 | 'name' => 'tinymce_init_chunk',
151 | 'desc' => 'Without this chunk NOTHING is editable. TinyMCE powerful API caters for all the sorts of editors used by tinyBlocks.js',
152 | 'type' => 'textfield',
153 | 'options' =>
154 | array (
155 | ),
156 | 'value' => 'st.tinymce_config',
157 | 'lexicon' => NULL,
158 | 'area' => '2. Manager Chunks Used by Template',
159 | ),
160 | 'manager_misc_buttons_chunk' =>
161 | array (
162 | 'name' => 'manager_misc_buttons_chunk',
163 | 'desc' => 'Add or remove buttons next to Manager save button. Richtext, Markdown and Code Editors...',
164 | 'type' => 'textfield',
165 | 'options' =>
166 | array (
167 | ),
168 | 'value' => 'st.save_buttons',
169 | 'lexicon' => NULL,
170 | 'area' => '2. Manager Chunks Used by Template',
171 | ),
172 | 'import_wrapper_chunk' =>
173 | array (
174 | 'name' => 'import_wrapper_chunk',
175 | 'desc' => 'To import existing content, simply add to the resource manager url this parameter &autoImport',
176 | 'type' => 'textfield',
177 | 'options' =>
178 | array (
179 | ),
180 | 'value' => 'st.importWrapper_tpl',
181 | 'lexicon' => NULL,
182 | 'area' => '2. Manager Chunks Used by Template',
183 | ),
184 | 'import_marker_chunk' =>
185 | array (
186 | 'name' => 'import_marker_chunk',
187 | 'desc' => 'To import existing content into Structures simply add this parameter to your resource url: &autoImport. import_marker_chunk will replace this MODX comment tag [[-STRUCTURES]] in your content. Please see your block_reel_chunk (st.snippets_base) for HTML guide',
188 | 'type' => 'textfield',
189 | 'options' =>
190 | array (
191 | ),
192 | 'value' => 'st.importMarker_tpl',
193 | 'lexicon' => NULL,
194 | 'area' => '2. Manager Chunks Used by Template',
195 | ),
196 | 'help_howto_chunk' =>
197 | array (
198 | 'name' => 'help_howto_chunk',
199 | 'desc' => 'This chunk will show when there is no content in the resource. Can also be accessed via keyboard shrct. standByStructure, when it has value, will replace this chunk.',
200 | 'type' => 'textfield',
201 | 'options' =>
202 | array (
203 | ),
204 | 'value' => 'st.help_howto',
205 | 'lexicon' => NULL,
206 | 'area' => '2. Manager Chunks Used by Template',
207 | ),
208 | 'all_structures_chunk' =>
209 | array (
210 | 'name' => 'all_structures_chunk',
211 | 'desc' => 'Store all your predefined structures (blocks / HTML snippets). MODX tags will not be processed for good reasons.',
212 | 'type' => 'textfield',
213 | 'options' =>
214 | array (
215 | ),
216 | 'value' => 'st.structures',
217 | 'lexicon' => NULL,
218 | 'area' => '2. Manager Chunks Used by Template',
219 | ),
220 | 'ace_mirror_init_chunk' =>
221 | array (
222 | 'name' => 'ace_mirror_init_chunk',
223 | 'desc' => 'Chunk to run CE (Code Editor)',
224 | 'type' => 'textfield',
225 | 'options' =>
226 | array (
227 | ),
228 | 'value' => 'st.ace_mirror_config',
229 | 'lexicon' => NULL,
230 | 'area' => '2. Manager Chunks Used by Template',
231 | ),
232 | 'sidebar_tab_title' =>
233 | array (
234 | 'name' => 'sidebar_tab_title',
235 | 'desc' => 'The tab title for Structures Tree. Set to hidden or empty to hide this panel. All your structures will still be available via shortcuts and dropdown menus.',
236 | 'type' => 'textfield',
237 | 'options' =>
238 | array (
239 | ),
240 | 'value' => 'Structures',
241 | 'lexicon' => NULL,
242 | 'area' => '3. Tab Text',
243 | ),
244 | 'content_tab_title' =>
245 | array (
246 | 'name' => 'content_tab_title',
247 | 'desc' => 'The tab title for resource content area. Set to hidden or empty to use default MODX content area.',
248 | 'type' => 'textfield',
249 | 'options' =>
250 | array (
251 | ),
252 | 'value' => 'Content',
253 | 'lexicon' => NULL,
254 | 'area' => '3. Tab Text',
255 | ),
256 | 'manager_js' =>
257 | array (
258 | 'name' => 'manager_js',
259 | 'desc' => 'Powered by tinyBlocks.js and TinyJSONGallery.js et al. Compile your own and even add other JS to tweak your resource. If MODX tags are not being processed, please enter correct value.',
260 | 'type' => 'textfield',
261 | 'options' =>
262 | array (
263 | ),
264 | 'value' => '[[++assets_url]]components/structures/js/structures_all.min.js',
265 | 'lexicon' => NULL,
266 | 'area' => '4. Structures File Urls',
267 | ),
268 | 'manager_css' =>
269 | array (
270 | 'name' => 'manager_css',
271 | 'desc' => 'This CSS file is necessary for fundamental functionality. It is compressed from source',
272 | 'type' => 'textfield',
273 | 'options' =>
274 | array (
275 | ),
276 | 'value' => '[[++assets_url]]components/structures/css/structures_all.min.css',
277 | 'lexicon' => NULL,
278 | 'area' => '4. Structures File Urls',
279 | ),
280 | 'donshakepeare_tinymce_js_plugins' =>
281 | array (
282 | 'name' => 'donshakepeare_tinymce_js_plugins',
283 | 'desc' => 'A compressed and preloaded pack of donshakepeare-beautifully-handcrafted TinyMCE plugins. No need to call said plugins in TinyMCE init. Compile yours from my github.com/donShakespeare',
284 | 'type' => 'textfield',
285 | 'options' =>
286 | array (
287 | ),
288 | 'value' => '[[++assets_url]]components/structures/js/donshakespeare_plugins.min.js',
289 | 'lexicon' => NULL,
290 | 'area' => '4. Structures File Urls',
291 | ),
292 | 'TinyMCE_skin_url' =>
293 | array (
294 | 'name' => 'TinyMCE_skin_url',
295 | 'desc' => 'Skin used through out Structures... http://skin.tinymce.com/ Build your own here from scratch or edit an existing skin by drag\'n\'dropping the skin.json',
296 | 'type' => 'textfield',
297 | 'options' =>
298 | array (
299 | ),
300 | 'value' => '[[++assets_url]]components/structures/tinymceskins/hamlet',
301 | 'lexicon' => NULL,
302 | 'area' => '4. Structures File Urls',
303 | ),
304 | 'CDN_Ace' =>
305 | array (
306 | 'name' => 'CDN_Ace',
307 | 'desc' => 'Leave empty to disable Syntax Highlighter Editor (Ace)....Default: https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
308 | 'type' => 'textfield',
309 | 'options' =>
310 | array (
311 | ),
312 | 'value' => 'https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.5/ace.js',
313 | 'lexicon' => NULL,
314 | 'area' => '4. Structures File Urls',
315 | ),
316 | );
317 |
318 | return $properties;
319 |
320 |
--------------------------------------------------------------------------------
/_build/data/slate/transport.chunks.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $chunks */
24 |
25 |
26 | $chunks = array();
27 |
28 | $chunks[1] = $modx->newObject('modChunk');
29 | $chunks[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'st.slate_importWrapper_tpl',
33 | 'description' => 'Template used by Structures to wrap content that has MODX comment tag, [[-TB-MARKER]]. Use the import tool or use Manager resource url parameter &autoImport. This chunk is sample using the Markdown block/structure.',
34 | 'properties' =>
35 | array (
36 | ),
37 | ), '', true, true);
38 | $chunks[1]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_importwrapper_tpl.chunk.html'));
39 |
40 | $chunks[2] = $modx->newObject('modChunk');
41 | $chunks[2]->fromArray(array (
42 | 'id' => 2,
43 | 'property_preprocess' => false,
44 | 'name' => 'st.slate_importMarker_tpl',
45 | 'description' => 'Structures uses this template to break content into blocks/structures. Existing Content must have MODX comment tag [[-TB-MARKER]] to use the import tool or to use Manager resource url this parameter &autoImport',
46 | 'properties' =>
47 | array (
48 | ),
49 | ), '', true, true);
50 | $chunks[2]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_importmarker_tpl.chunk.html'));
51 |
52 | $chunks[3] = $modx->newObject('modChunk');
53 | $chunks[3]->fromArray(array (
54 | 'id' => 3,
55 | 'property_preprocess' => false,
56 | 'name' => 'st.slate_structures',
57 | 'description' => 'New blocks and their respective triggers for your content. To hide this panel in sidebar, give it the name: hidden, in the Template Properties, sidebar_tab_title',
58 | 'properties' =>
59 | array (
60 | ),
61 | ), '', true, true);
62 | $chunks[3]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.slate_structures.chunk.html'));
63 |
64 | return $chunks;
65 |
--------------------------------------------------------------------------------
/_build/data/structures/transport.chunks.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $chunks */
24 |
25 |
26 | $chunks = array();
27 |
28 | $chunks[1] = $modx->newObject('modChunk');
29 | $chunks[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'st.ace_mirror_config',
33 | 'description' => 'Editor settings for Ace or CodeMirror(coming soon)',
34 | 'properties' =>
35 | array (
36 | ),
37 | ), '', true, true);
38 | $chunks[1]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.ace_mirror_config.chunk.html'));
39 |
40 | $chunks[2] = $modx->newObject('modChunk');
41 | $chunks[2]->fromArray(array (
42 | 'id' => 2,
43 | 'property_preprocess' => false,
44 | 'name' => 'st.help_howto',
45 | 'description' => 'Info that goes into modal triggered by Structures Help button',
46 | 'properties' =>
47 | array (
48 | ),
49 | ), '', true, true);
50 | $chunks[2]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.help_howto.chunk.html'));
51 |
52 | $chunks[3] = $modx->newObject('modChunk');
53 | $chunks[3]->fromArray(array (
54 | 'id' => 3,
55 | 'property_preprocess' => false,
56 | 'name' => 'st.tinymce_config',
57 | 'description' => 'Editor settings: Without this chunk no editing is possible.',
58 | 'properties' =>
59 | array (
60 | ),
61 | ), '', true, true);
62 | $chunks[3]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.tinymce_config.chunk.html'));
63 |
64 | $chunks[4] = $modx->newObject('modChunk');
65 | $chunks[4]->fromArray(array (
66 | 'id' => 4,
67 | 'property_preprocess' => false,
68 | 'name' => 'st.save_buttons',
69 | 'description' => 'Buttons that appear next to MODX Save/Duplicate buttons',
70 | 'properties' =>
71 | array (
72 | ),
73 | ), '', true, true);
74 | $chunks[4]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.save_buttons.chunk.html'));
75 |
76 | $chunks[5] = $modx->newObject('modChunk');
77 | $chunks[5]->fromArray(array (
78 | 'id' => 5,
79 | 'property_preprocess' => false,
80 | 'name' => 'st.importWrapper_tpl',
81 | 'description' => 'Template used by Structures to wrap content that has MODX comment tag, [[-STRUCTURES]]. Use the import tool or use Manager resource url parameter &autoImport. This chunk is sample using the Markdown block/structure.',
82 | 'properties' =>
83 | array (
84 | ),
85 | ), '', true, true);
86 | $chunks[5]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.importwrapper_tpl.chunk.html'));
87 |
88 | $chunks[6] = $modx->newObject('modChunk');
89 | $chunks[6]->fromArray(array (
90 | 'id' => 6,
91 | 'property_preprocess' => false,
92 | 'name' => 'st.importMarker_tpl',
93 | 'description' => 'Structures uses this template to break content into blocks/structures. Existing Content must have MODX comment tag [[-STRUCTURES]] to use the import tool or to use Manager resource url this parameter &autoImport',
94 | 'properties' =>
95 | array (
96 | ),
97 | ), '', true, true);
98 | $chunks[6]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.importmarker_tpl.chunk.html'));
99 |
100 | $chunks[7] = $modx->newObject('modChunk');
101 | $chunks[7]->fromArray(array (
102 | 'id' => 7,
103 | 'property_preprocess' => false,
104 | 'name' => 'st.structures',
105 | 'description' => 'New blocks and their respective triggers for your content. To hide this panel in sidebar, give it the name: hidden, in the Template Properties, sidebar_tab_title',
106 | 'properties' =>
107 | array (
108 | ),
109 | ), '', true, true);
110 | $chunks[7]->setContent(file_get_contents($sources['source_core'] . '/elements/chunks/st.structures.chunk.html'));
111 |
112 | return $chunks;
113 |
--------------------------------------------------------------------------------
/_build/data/structures/transport.plugins.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $plugins */
24 |
25 |
26 | $plugins = array();
27 |
28 | $plugins[1] = $modx->newObject('modPlugin');
29 | $plugins[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'Structures',
33 | 'description' => 'Structures Plugin fires on OnDocFormPrerender and only when said Resource has a MODX Template attached to $tvForCMRspecificity in this case "Structures" TV',
34 | 'properties' =>
35 | array (
36 | ),
37 | 'disabled' => false,
38 | ), '', true, true);
39 | $plugins[1]->setContent(file_get_contents($sources['source_core'] . '/elements/plugins/structures.plugin.php'));
40 |
41 | return $plugins;
42 |
--------------------------------------------------------------------------------
/_build/data/structures/transport.snippets.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $snippets */
24 |
25 |
26 | $snippets = array();
27 |
28 | $snippets[1] = $modx->newObject('modSnippet');
29 | $snippets[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'name' => 'Structures',
33 | 'description' => 'Used to parse Markdown, and to perform other cosmetic cleanups. Usage [[*content:Structures]]... It can take these options :Structures=markdown or :Structures=markdownE(default) or :Structures=parsedown or :Structures=parsedownE',
34 | 'properties' =>
35 | array (
36 | ),
37 | ), '', true, true);
38 | $snippets[1]->setContent(file_get_contents($sources['source_core'] . '/elements/snippets/structures.snippet.php'));
39 |
40 | return $snippets;
41 |
--------------------------------------------------------------------------------
/_build/data/structures/transport.templates.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $templates */
24 |
25 |
26 | $templates = array();
27 |
28 | $templates[1] = $modx->newObject('modTemplate');
29 | $templates[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => true,
32 | 'templatename' => 'Structures',
33 | 'description' => 'To use your own template, attach the Structures TV to your template. Load this template\'s default properties into yours directly or via psets and voila! OR, just duplicate this template. Done! Remember, you can use a property set as well.',
34 | 'icon' => 'icon-th',
35 | 'template_type' => 0,
36 | ), '', true, true);
37 | $templates[1]->setContent(file_get_contents($sources['source_core'] . '/elements/templates/structures.template.html'));
38 |
39 |
40 | $properties = include $sources['data'].'properties/properties.structures.template.php';
41 | $templates[1]->setProperties($properties);
42 | unset($properties);
43 |
44 | return $templates;
45 |
--------------------------------------------------------------------------------
/_build/data/structures/transport.tvs.php:
--------------------------------------------------------------------------------
1 | ', '', $o);
17 | $o = trim($o);
18 | return $o;
19 | }
20 | }
21 | /* @var $modx modX */
22 | /* @var $sources array */
23 | /* @var xPDOObject[] $templateVars */
24 |
25 |
26 | $templateVars = array();
27 |
28 | $templateVars[1] = $modx->newObject('modTemplateVar');
29 | $templateVars[1]->fromArray(array (
30 | 'id' => 1,
31 | 'property_preprocess' => false,
32 | 'type' => 'hidden',
33 | 'name' => 'Structures',
34 | 'caption' => 'Structures Wonderful TV',
35 | 'description' => 'Structures Plugin fires on OnDocFormPrerender and only when said Resource has a MODX Template attached to this hidden TV.',
36 | 'elements' => '',
37 | 'rank' => 0,
38 | 'display' => 'default',
39 | 'default_text' => '',
40 | 'properties' =>
41 | array (
42 | ),
43 | 'input_properties' =>
44 | array (
45 | 'allowBlank' => 'true',
46 | ),
47 | 'output_properties' =>
48 | array (
49 | ),
50 | ), '', true, true);
51 | return $templateVars;
52 |
--------------------------------------------------------------------------------
/_build/install.options/user.input.php:
--------------------------------------------------------------------------------
1 | tags and submit button) in a single string.
33 | *
34 | * The form will be shown to the user during install
35 | *
36 | * This example presents an HTML form to the user with two input fields
37 | * (you can have as many as you like).
38 | *
39 | * The user's entries in the form's input field(s) will be available
40 | * in any php resolvers with $modx->getOption('field_name', $options, 'default_value').
41 | *
42 | * You can use the value(s) to set system settings, snippet properties,
43 | * chunk content, etc. based on the user's preferences.
44 | *
45 | * One common use is to use a checkbox and ask the
46 | * user if they would like to install a resource for your
47 | * component (usually used only on install, not upgrade).
48 | */
49 |
50 | /* This is an example. Modify it to meet your needs.
51 | * The user's input would be available in a resolver like this:
52 | *
53 | * $changeSiteName = (! empty($modx->getOption('change_sitename', $options, ''));
54 | * $siteName = $modx->getOption('sitename', $options, '').
55 | *
56 | * */
57 |
58 | $output = '
Structures You are about to redefine the way you handle content in MODX
59 |
60 | 1. Create a new resource and attach Structures Template to it
61 |
62 | 2. Or use your own Template: duplicate Structures Template so that you have all the Template Default properties
63 |
64 | 3. If you already have your own Template, simply attach Structures hidden TV to it, and create a PropertySet anywhere in MODX. Done!
65 |
66 | 4. If you use RichText, don\'t forget to configure the editor first. Or just stick with Markdown :)
67 |
68 |
69 |
70 |
71 | ';
72 |
73 | return $output;
--------------------------------------------------------------------------------
/_build/resolvers/category.resolver.php:
--------------------------------------------------------------------------------
1 | log(modX::LOG_LEVEL_ERROR, '[Category Resolver] Missing field: ' . $field);
39 | return false;
40 | }
41 | }
42 | return true;
43 | }
44 | }
45 | if ($object->xpdo) {
46 | $modx =& $object->xpdo;
47 | switch ($options[xPDOTransport::PACKAGE_ACTION]) {
48 | case xPDOTransport::ACTION_INSTALL:
49 | case xPDOTransport::ACTION_UPGRADE:
50 |
51 | $intersects = array (
52 | 'Structures' => array (
53 | 'category' => 'Structures',
54 | 'parent' => '',
55 | ),
56 | 'Lector' => array (
57 | 'category' => 'Lector',
58 | 'parent' => 'Structures',
59 | ),
60 | 'Slate' => array (
61 | 'category' => 'Slate',
62 | 'parent' => 'Structures',
63 | ),
64 | );
65 |
66 | if (is_array($intersects)) {
67 | foreach ($intersects as $k => $fields) {
68 | /* make sure we have all fields */
69 | if (!checkFields('category,parent', $fields)) {
70 | continue;
71 | }
72 | $categoryObj = $modx->getObject('modCategory', array('category' => $fields['category']));
73 | if (!$categoryObj) {
74 | continue;
75 | }
76 | $parentObj = $modx->getObject('modCategory', array('category' => $fields['parent']));
77 | if ($parentObj) {
78 | $categoryObj->set('parent', $parentObj->get('id'));
79 | }
80 | $categoryObj->save();
81 | }
82 | }
83 | break;
84 |
85 | case xPDOTransport::ACTION_UNINSTALL:
86 | break;
87 | }
88 | }
89 |
90 | return true;
--------------------------------------------------------------------------------
/_build/resolvers/plugin.resolver.php:
--------------------------------------------------------------------------------
1 | log(modX::LOG_LEVEL_ERROR, '[Plugin Resolver] Missing field: ' . $field);
41 | return false;
42 | }
43 | }
44 | return true;
45 | }
46 | }
47 |
48 |
49 | $newEvents = array (
50 | );
51 |
52 |
53 | if ($object->xpdo) {
54 | $modx =& $object->xpdo;
55 | switch ($options[xPDOTransport::PACKAGE_ACTION]) {
56 | case xPDOTransport::ACTION_INSTALL:
57 | case xPDOTransport::ACTION_UPGRADE:
58 |
59 | foreach($newEvents as $k => $fields) {
60 |
61 | $event = $modx->getObject('modEvent', array('name' => $fields['name']));
62 | if (!$event) {
63 | $event = $modx->newObject('modEvent');
64 | if ($event) {
65 | $event->fromArray($fields, "", true, true);
66 | $event->save();
67 | }
68 | }
69 | }
70 |
71 | $intersects = array (
72 | 0 => array (
73 | 'pluginid' => 'Structures',
74 | 'event' => 'OnDocFormPrerender',
75 | 'priority' => '0',
76 | 'propertyset' => '0',
77 | ),
78 | );
79 |
80 | if (is_array($intersects)) {
81 | foreach ($intersects as $k => $fields) {
82 | /* make sure we have all fields */
83 | if (!checkFields('pluginid,event,priority,propertyset', $fields)) {
84 | continue;
85 | }
86 | $event = $modx->getObject('modEvent', array('name' => $fields['event']));
87 |
88 | $plugin = $modx->getObject('modPlugin', array('name' => $fields['pluginid']));
89 | $propertySetObj = null;
90 | if (!empty($fields['propertyset'])) {
91 | $propertySetObj = $modx->getObject('modPropertySet',
92 | array('name' => $fields['propertyset']));
93 | }
94 | if (!$plugin || !$event) {
95 | $modx->log(xPDO::LOG_LEVEL_ERROR, 'Could not find Plugin and/or Event ' .
96 | $fields['plugin'] . ' - ' . $fields['event']);
97 | continue;
98 | }
99 | $pluginEvent = $modx->getObject('modPluginEvent', array('pluginid'=>$plugin->get('id'),'event' => $fields['event']) );
100 |
101 | if (!$pluginEvent) {
102 | $pluginEvent = $modx->newObject('modPluginEvent');
103 | }
104 | if ($pluginEvent) {
105 | $pluginEvent->set('event', $fields['event']);
106 | $pluginEvent->set('pluginid', (integer) $plugin->get('id'));
107 | $pluginEvent->set('priority', (integer) $fields['priority']);
108 | if ($propertySetObj) {
109 | $pluginEvent->set('propertyset', (integer) $propertySetObj->get('id'));
110 | } else {
111 | $pluginEvent->set('propertyset', 0);
112 | }
113 |
114 | }
115 | if (! $pluginEvent->save()) {
116 | $modx->log(xPDO::LOG_LEVEL_ERROR, 'Unknown error saving pluginEvent for ' .
117 | $fields['plugin'] . ' - ' . $fields['event']);
118 | }
119 | }
120 | }
121 | break;
122 |
123 | case xPDOTransport::ACTION_UNINSTALL:
124 | foreach($newEvents as $k => $fields) {
125 | $event = $modx->getObject('modEvent', array('name' => $fields['name']));
126 | if ($event) {
127 | $event->remove();
128 | }
129 | }
130 | break;
131 | }
132 | }
133 |
134 | return true;
--------------------------------------------------------------------------------
/_build/resolvers/structures.resolver.php:
--------------------------------------------------------------------------------
1 | xpdo) {
30 | $modx =& $object->xpdo;
31 | switch ($options[xPDOTransport::PACKAGE_ACTION]) {
32 | case xPDOTransport::ACTION_INSTALL:
33 | case xPDOTransport::ACTION_UPGRADE:
34 | /* [[+code]] */
35 | break;
36 |
37 | case xPDOTransport::ACTION_UNINSTALL:
38 | break;
39 | }
40 | }
41 |
42 | return true;
--------------------------------------------------------------------------------
/_build/resolvers/tv.resolver.php:
--------------------------------------------------------------------------------
1 | log(modX::LOG_LEVEL_ERROR, '[TV Resolver] Missing field: ' . $field);
38 | return false;
39 | }
40 | }
41 | return true;
42 | }
43 | }
44 |
45 | if ($object->xpdo) {
46 | $modx =& $object->xpdo;
47 | switch ($options[xPDOTransport::PACKAGE_ACTION]) {
48 | case xPDOTransport::ACTION_INSTALL:
49 | case xPDOTransport::ACTION_UPGRADE:
50 |
51 | $intersects = array (
52 | 0 => array (
53 | 'templateid' => 'Structures',
54 | 'tmplvarid' => 'Structures',
55 | 'rank' => 0,
56 | ),
57 | );
58 |
59 | if (is_array($intersects)) {
60 | foreach ($intersects as $k => $fields) {
61 | /* make sure we have all fields */
62 | if (!checkFields('tmplvarid,templateid', $fields)) {
63 | continue;
64 | }
65 | $tv = $modx->getObject('modTemplateVar', array('name' => $fields['tmplvarid']));
66 | if ($fields['templateid'] == 'default') {
67 | $template = $modx->getObject('modTemplate', $modx->getOption('default_template'));
68 | } else {
69 | $template = $modx->getObject('modTemplate', array('templatename' => $fields['templateid']));
70 | }
71 | if (!$tv || !$template) {
72 | $modx->log(xPDO::LOG_LEVEL_ERROR, 'Could not find Template and/or TV ' .
73 | $fields['templateid'] . ' - ' . $fields['tmplvarid']);
74 | continue;
75 | }
76 | $tvt = $modx->getObject('modTemplateVarTemplate', array('templateid' => $template->get('id'), 'tmplvarid' => $tv->get('id')));
77 | if (! $tvt) {
78 | $tvt = $modx->newObject('modTemplateVarTemplate');
79 | }
80 | if ($tvt) {
81 | $tvt->set('tmplvarid', $tv->get('id'));
82 | $tvt->set('templateid', $template->get('id'));
83 | if (isset($fields['rank'])) {
84 | $tvt->set('rank', $fields['rank']);
85 | } else {
86 | $tvt->set('rank', 0);
87 | }
88 | if (!$tvt->save()) {
89 | $modx->log(xPDO::LOG_LEVEL_ERROR, 'Unknown error creating templateVarTemplate for ' .
90 | $fields['templateid'] . ' - ' . $fields['tmplvarid']);
91 | }
92 | } else {
93 | $modx->log(xPDO::LOG_LEVEL_ERROR, 'Unknown error creating templateVarTemplate for ' .
94 | $fields['templateid'] . ' - ' . $fields['tmplvarid']);
95 | }
96 |
97 |
98 | }
99 |
100 | }
101 | break;
102 |
103 | case xPDOTransport::ACTION_UNINSTALL:
104 | break;
105 | }
106 | }
107 |
108 | return true;
--------------------------------------------------------------------------------
/assets/components/structures/css/structures_all.css:
--------------------------------------------------------------------------------
1 | @import "structures_mgr.css";
2 |
3 | /* Richtext CSS for Structures */
4 | .tb-custom-fc * {
5 | /* border: 0;
6 | padding: 0;
7 | margin: 0;
8 | background: 50% 50% no-repeat; */
9 | text-decoration: none;
10 | color: inherit;
11 | box-sizing: border-box;
12 | font-weight: 400;
13 | }
14 | .tb-custom-fc :focus {
15 | outline: 0;
16 | }
17 | .tb-custom-fc b, .tb-custom-fc b *, .tb-custom-fc strong, .tb-custom-fc strong * {
18 | font-weight: 700;
19 | }
20 | .tb-custom-fc ol, .tb-custom-fc ul {
21 | list-style: none;
22 | }
23 | .tb-custom-fc button, .tb-custom-fc input, .tb-custom-fc input:not([type]), .tb-custom-fc input[type=color], .tb-custom-fc input[type=text], .tb-custom-fc input[type=time], .tb-custom-fc input[type=url], .tb-custom-fc input[type=week], .tb-custom-fc input[type=button], .tb-custom-fc input[type=reset], .tb-custom-fc input[type=submit], .tb-custom-fc input[type=date], .tb-custom-fc input[type=datetime], .tb-custom-fc input[type=datetime-local], .tb-custom-fc input[type=email], .tb-custom-fc input[type=month], .tb-custom-fc input[type=number], .tb-custom-fc input[type=password], .tb-custom-fc input[type=search], .tb-custom-fc input[type=tel], .tb-custom-fc pre, .tb-custom-fc select, .tb-custom-fc textarea {
24 | font: inherit;
25 | }
26 |
27 | .st-html .tb-custom-fc {
28 | font-family: Lato !important;
29 | font-size: 14px;
30 | color: #828282;
31 | }
32 | .st-html .tb-custom-fc h1, .st-html .tb-custom-fc h2, .st-html .tb-custom-fc h3, .st-html .tb-custom-fc h4, .st-html .tb-custom-fc h5, .st-html .tb-custom-fc h6 {
33 | font-family: aileron;
34 | font-weight: 200;
35 | line-height: 1.4em;
36 | margin: 1rem 0;
37 | }
38 | .st-html .tb-custom-fc h1 {
39 | font-size: 34px;
40 | }
41 | .st-html .tb-custom-fc h2 {
42 | font-size: 30px;
43 | }
44 | .st-html .tb-custom-fc h3 {
45 | font-size: 26px;
46 | }
47 | .st-html .tb-custom-fc h4 {
48 | font-size: 22px;
49 | }
50 | .st-html .tb-custom-fc h5 {
51 | font-size: 18px;
52 | }
53 | .st-html .tb-custom-fc h6 {
54 | font-size: 14px;
55 | }
56 | .st-html .tb-custom-fc p {
57 | margin: 1rem 0;
58 | }
59 | .st-html .tb-custom-fc p:first-of-type, .st-html .tb-custom-fc h1:first-of-type {
60 | margin-top: 0;
61 | }
62 | .st-html .tb-custom-fc ol, .st-html .tb-custom-fc ul {
63 | margin-left: 15px;
64 | list-style-position: outside;
65 | margin-bottom: 20px;
66 | }
67 | .st-html .tb-custom-fc ol li, .st-html .tb-custom-fc ul li {
68 | margin-left: 10px;
69 | margin-bottom: 10px;
70 | color: #828282;
71 | }
72 | .st-html .tb-custom-fc ul {
73 | list-style-type: disc;
74 | }
75 | .st-html .tb-custom-fc ol {
76 | list-style-type: decimal;
77 | }
78 | .st-html .tb-custom-fc a[href] {
79 | text-decoration: underline;
80 | }
81 | .st-html .tb-custom-fc table {
82 | width: 100%;
83 | border-spacing: 0;
84 | border-collapse: separate;
85 | border: 1px solid #aaa;
86 | }
87 | .st-html .tb-custom-fc code {
88 | background: rgb(241, 241, 241);
89 | padding: 0 0.4rem;
90 | margin: 0 0.4rem!important;
91 | color: #000!important;
92 | font-style:italic!important;
93 | border-radius:0.5rem;
94 | }
95 |
96 | .st-html .tb-custom-fc pre code {
97 | background: inherit;
98 | padding: 0;
99 | margin: 0;
100 | color: inherit;
101 | font-style:none;
102 | border-radius:0;
103 | }
104 |
105 |
106 | .st-html .tb-custom-fc table tr:nth-child(even) {
107 | background: #FAFAFA;
108 | }
109 | .st-html .tb-custom-fc table caption, .st-html .tb-custom-fc table td, .st-html .tb-custom-fc table th {
110 | padding: 15px 7px;
111 | font: inherit;
112 | }
113 | .st-html .tb-custom-fc table th {
114 | font-weight: 400;
115 | color: #6E6E6E;
116 | background-position: 100% 100%;
117 | background-size: 2px 10px;
118 | background-repeat: no-repeat;
119 | }
120 | .st-html .tb-custom-fc table th:last-child {
121 | background: 0 0;
122 | }
123 | .st-html .tb-custom-fc blockquote{
124 | padding: .5rem 1rem;
125 | margin-bottom: 1rem;
126 | font-size: 1rem;
127 | border-left: 0.25rem solid #eceeef;
128 | line-height: 1.5;
129 | color: #818a91;
130 | }
--------------------------------------------------------------------------------
/assets/components/structures/css/structures_all.min.css:
--------------------------------------------------------------------------------
1 | .tb-modx-main-wrapper{padding:0}#modx-abtn-save,#ta{display:none!important;visibility:hidden!important;opacity:0!important}.x-panel-body.x-panel-body-noheader.x-panel-body-noborder{overflow-x:hidden!important}.modx-browser{z-index:99999!important}#modx-action-buttons.tinyBlocksDistraction,#modx-header.tinyBlocksDistraction,#modx-resource-content>.x-panel-header.tinyBlocksDistraction,#modx-resource-tabs .x-tab-panel-header.x-tab-panel-header-noborder.x-unselectable.x-tab-panel-header-plain.tinyBlocksDistraction,#modx-resource-tabs.tinyBlocksDistraction{display:none!important}#modx-action-buttons.tinyBlocksDistraction,#modx-content.tinyBlocksDistraction{top:0!important}#tinyBlocksSideWr .x-panel-body.x-panel-body-noheader.x-panel-body-noborder{height:auto!important}.x-window.x-window-plain.x-window-dlg{min-width:310px!important;width:auto!important}.x-window.x-window-plain.x-window-dlg .x-window-body{width:auto!important}div.tb-gallery-tv:before{content:"";position:absolute;display:block;z-index:9;width:102%;height:100%;background:rgba(242,242,242,.9);text-align:center;cursor:pointer}div.tb-gallery-tv:after{content:"Open Main Gallery (g + t)";position:absolute;display:block;z-index:9;width:200px;height:17px;top:23%;left:0;bottom:23%;right:0;margin:auto;background:rgba(45,51,56,1);color:#fff;text-align:center;cursor:pointer;border-radius:5px;padding:7px 10px}.st-html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:1rem;line-height:1.5;color:#55595c;background-color:#fff;position:relative;min-height:100%;overflow:hidden!important}.st-html [tabindex="-1"]:focus{outline:0!important}.st-container-fluid:empty::before,.st-outer::before{text-align:center}.st-container-fluid{margin-left:auto;margin-right:auto;padding:3.5rem 1.5rem 10rem 3rem;min-height:20rem}.st-container-fluid.tb-lone-block{padding-left:1.75rem!important}.tb-guide{max-width:600px;height:380px;display:block;overflow:auto}.tinyBlocksRowsWrapperClass .tb-guide{padding:0 2rem;font-size:1rem;color:#555;height:auto;width:auto;max-width:100%}.tb-guide li,.tb-guide p{margin:1rem 0}.tb-guide li{margin-left:.29rem}.tb-guide ol{list-style-type:decimal!important;list-style:initial;padding:0 0 0 1rem}.tb-guide kbd{background:rgba(241,241,241,1);padding:1px 3px;border-radius:5px;color:#000;font-size:98%}.st-html .coder{height:auto!important;z-index:3}.st-html [data-origin] pre.ace_editor{height:300px!important}#blockControlBase,#blockSnippetBar .tinyBlocksRowTempHolderClass,.st-outer.tb-lone-block .mce-tinyBlocksTools,.st-outer.tb-lone-block .tb-select,.st-outer.tb-lone-block:before,textarea.tb-tiny-rc-sub{display:none!important}#blockSnippetBar ol{list-style-type:none;counter-reset:structures-counter;padding:2em 0;text-align:left;color:#555}#blockSnippetBar ol li:before{content:counter(structures-counter) ". ";counter-increment:structures-counter;float:left;padding:.5rem 0 0 1rem}#blockSnippetBar ol li{font-size:.7rem!important;background-color:#fff!important;border-bottom:.15rem rgba(241,241,241,1)dashed}#blockSnippetBar h1{padding:2rem 0 .5rem 1rem;font-size:1rem;cursor:help}#blockSnippetBar [data-tinyblocks-trigger],.tb-ui-drag-helper{display:block!important;cursor:pointer;color:inherit;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif!important;font-weight:500!important;line-height:1.5!important;padding:.3rem 0 .2rem 2.2rem!important;font-size:1rem!important;text-align:left;max-width:15rem}#blockSnippetBar [data-tinyblocks-trigger].tb-onRoute,#blockSnippetBar li.tb-onRoute{visibility:hidden!important}.tb-ui-drag-helper{position:fixed!important;z-index:999999!important;border:.15rem rgba(241,241,241,1)dashed!important;background-color:#fff!important;text-align:center}#blockSnippetBar li:last-of-type{border-bottom:0}#blockSnippetBar ol li:hover{background-color:rgba(241,241,241,.5)!important}#tb-random-tip{margin:2rem auto;display:none;width:80%;font-style:italic}#tb-random-tip:before{content:"Tip:";display:block;font-style:italic;text-decoration:underline}#tinyBlocksButtonHolder button,#tinyBlocksTVButtonHolder button{padding:7.5px!important;font-style:normal!important;font-size:13px!important}#tinyBlocksButtonHolder .mce-tinyBlocksButton,#tinyBlocksTVButtonHolder .mce-tinyBlocksButton{margin:0 0 0 7px!important;display:none;border:0}#tinyBlocksButtonHolder .mce-txt,#tinyBlocksTVButtonHolder .mce-txt{vertical-align:middle}.tinyBlocksHTMLbtn{text-align:center}.st-outer.tb-nested-no{counter-increment:st-row-counter}.st-outer.tb-nested-yes{counter-increment:st-row-counter-nested}.st-outer.tb-nested-no::before{content:counter(st-row-counter)}.st-outer.tb-nested-yes::before{content:counter(st-row-counter-nested)}.st-outer::before{line-height:.8;font-size:.7rem;font-weight:600;vertical-align:middle;background-color:rgba(241,241,241,1)}.ui-selected.st-outer::before{background-color:rgba(45,51,56,1);color:rgba(241,241,241,1)}.tb-spacer{display:block!important;position:relative;height:1rem}.st-outer:first-of-type .tb-spacer{margin-top:0}.tb-spacer:hover{background:rgba(241,241,241,.15)}.mce-tinyBlocksTools,.st-outer::before,.tb-select{position:absolute!important;display:block;top:1rem!important;left:-1.75rem!important;width:1.25rem!important;height:.95rem;padding-top:.3rem;z-index:2!important;border-radius:.15rem}.tb-select.tb-nested-no{cursor:move}.tb-name,.tb-title{display:block!important;width:90%!important;margin:auto;font-size:.7rem!important;text-align:center!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;outline:0!important}.tb-title *{display:none!important}.tb-name{position:absolute;right:0;width:auto!important}#blockSnippetBar.ui-drag,#blockSnippetBar.ui-drag [data-tinyblocks-trigger],body.ui-drag,body.ui-drag *{cursor:move!important}.st-outer{position:relative;padding:0!important;margin:0 0 3.5rem}.tinyBlocksHTMLwrapper{margin-left:auto;margin-right:auto;padding:2rem 4rem 0}.tinyBlocksHTML{width:95%;height:8rem;background:rgba(242,242,242,.26)!important;border:.2rem dashed #f1f1f1!important;border-top:0;padding:2%;resize:vertical}.mce-tinyBlocksTools{top:2.5rem!important;border:0!important;right:-1.35rem!important;cursor:pointer!important}.st-outer.tb-nested-yes::before,.tb-nested-yes .mce-tinyBlocksTools,.tb-nested-yes .tb-select{margin-top:-1rem;left:0!important}.mce-tinyBlocksTools button{padding:0!important}.mce-tinyBlocksTools i{padding:0!important;position:absolute!important;top:0;bottom:0;left:0;right:0;margin:auto!important}.st-outer .mce-tinyBlocksTools .mce-menu-item,.tinyBlocksHTMLwrapper .mce-tinyBlocksTools .mce-menu-item{padding:.25rem!important;display:inline-block!important}.mce-menu{width:auto!important;min-width:100px!important;border-radius:0!important}.mce-menu,.mce-menu.mce-context-menu{padding-top:0!important;padding-bottom:0!important}.mce-menu-item span.mce-text{background-color:transparent!important}.mce-menu-item:hover span.mce-text{background-color:transparent!important;color:#fff!important}.tinyBlocksDebug{position:relative;background:#fff;display:block;font-weight:700;padding:3%;border-radius:5px;color:#000;margin:auto;height:25px;overflow:hidden;word-wrap:break-word}.tinyBlocksDebug:hover{height:auto;overflow:auto}.tinyBlocksDebug .tinyBlocksDebug h3,.tinyBlocksDebug h2{text-align:center}.tinyBlocksDebug b{color:#818a91}.tinyBlocksDebug b:after{content:": "}.tinyBlocksDebug i{color:#28a697}.tinyBlocksDebug span{display:block;border:2px dotted #818a91;border-bottom:0;margin:0;overflow:auto;padding:5px}.tinyBlocksDebug .imp{background:#2b3b43}#tinyBlocksThrobber{display:block!important;position:fixed!important;width:31px;height:31px;top:0;left:0;bottom:0;right:0;margin:auto;opacity:.24!important;background:#f8f8f8 url(../img/loader.gif) no-repeat center center!important;z-index:99999999!important}.st-row{margin-left:0!important;margin-right:0!important}.st-shrink{height:2rem;overflow:auto!important;overflow-x:hidden!important}.st-hidden{opacity:.2}.st-new-block::before{content:"New";position:absolute;left:0;color:rgba(45,51,56,1)!important;font-size:.65rem!important;font-weight:700;z-index:10;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif}.tb-wrapper-tlb img{max-width:100%!important;max-height:100%!important}.mce-tinymce.mce-tinymce-inline.mce-arrow.mce-container.mce-panel.mce-floatpanel.mce-arrow-up{z-index:8900!important}.st-html .mce-edit-focus{outline:0!important}.st-html .ui-state-highlight{display:block!important;height:5rem;margin:1.5rem 0 5rem;border:.2rem rgba(241,241,241,1)dashed}.tb-nested-wrapper .ui-state-highlight{margin:1.5rem!important}.st-html .mce-menu{width:auto!important;min-width:100px!important;border-radius:0!important}.st-html #aceMoreSuperOptions_wrapper{position:absolute!important;z-index:9!important;right:2rem!important;top:-.5rem!important;width:8rem}.st-html #aceMoreSuperOptions_wrapper_sub{margin-top:0!important}.tb-nested-yes [class^=tb-tiny-],.tb-wrapper-tlb{padding:1rem;transition:all .1s ease-in-out;border:.2rem rgba(241,241,241,1)dashed;min-height:3rem;overflow-y:auto}.tb-nested-yes [class^=tb-tiny-]{margin:1.5rem}.tb-nested-yes.ui-selected [class^=tb-tiny-],.ui-selected .tb-wrapper-tlb{border-color:rgba(45,51,56,1)}.tb-nested-yes [class^=tb-tiny-]:hover,.ui-selected .tb-wrapper-tlb:hover{border-color:rgba(45,51,56,.7)}.tb-nested-yes [class^=tb-tiny-]:focus,.ui-selected .tb-wrapper-tlb:focus{border-color:rgba(45,51,56,.5)}.tb-ui-multiple-select,.tb-ui-single-select:not(.tb-ui-drag-helper){padding-top:1rem!important;margin-top:-1.5rem}.tb-ui-multiple-select .tb-spacer,.tb-ui-single-select .tb-spacer{display:none!important}.tb-ui-multiple-select.st-outer .tb-wrapper-tlb{border-style:solid;background:rgba(241,241,241,1)}.tb-ui-multiple-select.st-outer:after{content:"multiple structures";display:block;position:absolute;background:rgba(45,51,56,1)!important;padding:0 1rem;color:#fff}.tb-nested-yes [class^=tb-tiny-]:focus,.tb-nested-yes [class^=tb-tiny-]:hover,.tb-wrapper-tlb:focus,.tb-wrapper-tlb:hover{border-color:#dfdfdf}.tb-custom-md:empty:before,.tb-tiny-md:empty:before{display:block;transition:all .1s ease-in-out}.tb-custom-md{transition:opacity 1s,ease-in-out;position:relative;font-family:Menlo,Monaco,Consolas,"Courier New",monospace!important;font-size:.875rem!important;line-height:normal}.tb-custom-md p br,.tb-custom-md p:empty{margin:1rem 0}.tb-custom-im{cursor:pointer!important}.tb-custom-im img{display:block;max-width:none;max-height:16.875rem;margin-left:auto;margin-right:auto}.tb-custom-im:hover img{opacity:.8}[class*=tb-tiny-]{word-wrap:break-word}.st-html pre[contenteditable=false][data-mce-selected]{box-shadow:0 2px 5px 0 rgba(0,0,0,.16),0 2px 10px 0 rgba(0,0,0,.12)!important}.tb-custom-dc,.tb-custom-dc *{cursor:pointer!important}.tb-custom-dc pre{box-shadow:none!important;padding:1rem;overflow:hidden;outline:0!important}.tb-custom-fc [contenteditable=false]{padding:.5rem;margin:1rem 0;outline:0!important;border:.15rem #f1f1f1 dashed}.tb-custom-fc [contenteditable=false][data-mce-selected]{border-color:#233549}.tb-custom-fc [contenteditable=false],:not(*){cursor:move}.tb-custom-fc [contenteditable=false] [contenteditable=true]:hover{outline-color:#f1f1f1!important}.tb-custom-dc .mce-visual-caret,.tb-custom-dc [data-mce-caret],.tb-custom-im .mce-visual-caret{display:none!important;opacity:0!important;visibility:hidden!important}.tb-custom-fc *{text-decoration:none;color:inherit;box-sizing:border-box;font-weight:400}.tb-custom-fc :focus{outline:0}.tb-custom-fc b,.tb-custom-fc b *,.tb-custom-fc strong,.tb-custom-fc strong *{font-weight:700}.tb-custom-fc ol,.tb-custom-fc ul{list-style:none}.tb-custom-fc button,.tb-custom-fc input,.tb-custom-fc input:not([type]),.tb-custom-fc input[type=button],.tb-custom-fc input[type=color],.tb-custom-fc input[type=date],.tb-custom-fc input[type=datetime-local],.tb-custom-fc input[type=datetime],.tb-custom-fc input[type=email],.tb-custom-fc input[type=month],.tb-custom-fc input[type=number],.tb-custom-fc input[type=password],.tb-custom-fc input[type=reset],.tb-custom-fc input[type=search],.tb-custom-fc input[type=submit],.tb-custom-fc input[type=tel],.tb-custom-fc input[type=text],.tb-custom-fc input[type=time],.tb-custom-fc input[type=url],.tb-custom-fc input[type=week],.tb-custom-fc pre,.tb-custom-fc select,.tb-custom-fc textarea{font:inherit}.st-html .tb-custom-fc{font-family:Lato!important;font-size:14px;color:#828282}.st-html .tb-custom-fc h1,.st-html .tb-custom-fc h2,.st-html .tb-custom-fc h3,.st-html .tb-custom-fc h4,.st-html .tb-custom-fc h5,.st-html .tb-custom-fc h6{font-family:aileron;font-weight:200;line-height:1.4em;margin:1rem 0}.st-html .tb-custom-fc h1{font-size:34px}.st-html .tb-custom-fc h2{font-size:30px}.st-html .tb-custom-fc h3{font-size:26px}.st-html .tb-custom-fc h4{font-size:22px}.st-html .tb-custom-fc h5{font-size:18px}.st-html .tb-custom-fc h6{font-size:14px}.st-html .tb-custom-fc p{margin:1rem 0}.st-html .tb-custom-fc h1:first-of-type,.st-html .tb-custom-fc p:first-of-type{margin-top:0}.st-html .tb-custom-fc ol,.st-html .tb-custom-fc ul{margin-left:15px;list-style-position:outside;margin-bottom:20px}.st-html .tb-custom-fc ol li,.st-html .tb-custom-fc ul li{margin-left:10px;margin-bottom:10px;color:#828282}.st-html .tb-custom-fc ul{list-style-type:disc}.st-html .tb-custom-fc ol{list-style-type:decimal}.st-html .tb-custom-fc a[href]{text-decoration:underline}.st-html .tb-custom-fc table{width:100%;border-spacing:0;border-collapse:separate;border:1px solid #aaa}.st-html .tb-custom-fc code{background:#f1f1f1;padding:0 .4rem;margin:0 .4rem!important;color:#000!important;font-style:italic!important;border-radius:.5rem}.st-html .tb-custom-fc pre code{background:inherit;padding:0;margin:0;color:inherit;font-style:none;border-radius:0}.st-html .tb-custom-fc table tr:nth-child(even){background:#FAFAFA}.st-html .tb-custom-fc table caption,.st-html .tb-custom-fc table td,.st-html .tb-custom-fc table th{padding:15px 7px;font:inherit}.st-html .tb-custom-fc table th{font-weight:400;color:#6E6E6E;background-position:100% 100%;background-size:2px 10px;background-repeat:no-repeat}.st-html .tb-custom-fc table th:last-child{background:0 0}.st-html .tb-custom-fc blockquote{padding:.5rem 1rem;margin-bottom:1rem;font-size:1rem;border-left:.25rem solid #eceeef;line-height:1.5;color:#818a91}
--------------------------------------------------------------------------------
/assets/components/structures/gallery/colorbox/colorbox.css:
--------------------------------------------------------------------------------
1 | /*
2 | Colorbox Core Style:
3 | The following CSS is consistent between example themes and should not be altered.
4 | */
5 | #colorbox, #cboxOverlay, #cboxWrapper{position:absolute; top:0; left:0; z-index:9999; overflow:hidden; -webkit-transform: translate3d(0,0,0);}
6 | #cboxWrapper {max-width:none;}
7 | #cboxOverlay{position:fixed; width:100%; height:100%;}
8 | #cboxMiddleLeft, #cboxBottomLeft{clear:left;}
9 | #cboxContent{position:relative;}
10 | #cboxLoadedContent{overflow:auto; -webkit-overflow-scrolling: touch;}
11 | #cboxTitle{margin:0;}
12 | #cboxLoadingOverlay, #cboxLoadingGraphic{position:absolute; top:0; left:0; width:100%; height:100%;}
13 | #cboxPrevious, #cboxNext, #cboxClose, #cboxSlideshow{cursor:pointer;}
14 | .cboxPhoto{float:left; margin:auto; border:0; display:block; max-width:none; -ms-interpolation-mode:bicubic;}
15 | .cboxIframe{width:100%; height:100%; display:block; border:0; padding:0; margin:0;}
16 | #colorbox, #cboxContent, #cboxLoadedContent{box-sizing:content-box; -moz-box-sizing:content-box; -webkit-box-sizing:content-box;}
17 |
18 | /*
19 | User Style:
20 | Change the following styles to modify the appearance of Colorbox. They are
21 | ordered & tabbed in a way that represents the nesting of the generated HTML.
22 | */
23 | #cboxOverlay{background:#000; opacity: 0.9; filter: alpha(opacity = 90);}
24 | #colorbox{outline:0;}
25 | #cboxContent{margin-top:20px;background:#000;}
26 | .cboxIframe{background:#fff;}
27 | #cboxError{padding:50px; border:1px solid #ccc;}
28 | #cboxLoadedContent{border:5px solid #000; background:#fff;}
29 | #cboxTitle{position:absolute; top:-20px; left:0; color:#ccc;}
30 | #cboxCurrent{position:absolute; top:-20px; right:0px; color:#ccc;}
31 | #cboxLoadingGraphic{background:url(images/loading.gif) no-repeat center center;}
32 |
33 | /* these elements are buttons, and may need to have additional styles reset to avoid unwanted base styles */
34 | #cboxPrevious, #cboxNext, #cboxSlideshow, #cboxClose {border:0; padding:0; margin:0; overflow:visible; width:auto; background:none; }
35 |
36 | /* avoid outlines on :active (mouseclick), but preserve outlines on :focus (tabbed navigating) */
37 | #cboxPrevious:active, #cboxNext:active, #cboxSlideshow:active, #cboxClose:active {outline:0;}
38 |
39 | #cboxSlideshow{position:absolute; top:-20px; right:90px; color:#fff;}
40 | #cboxPrevious{position:absolute; top:50%; left:5px; margin-top:-32px; background:url(images/controls.png) no-repeat top left; width:28px; height:65px; text-indent:-9999px;}
41 | #cboxPrevious:hover{background-position:bottom left;}
42 | #cboxNext{position:absolute; top:50%; right:5px; margin-top:-32px; background:url(images/controls.png) no-repeat top right; width:28px; height:65px; text-indent:-9999px;}
43 | #cboxNext:hover{background-position:bottom right;}
44 | #cboxClose{position:absolute; top:5px; right:5px; display:block; background:url(images/controls.png) no-repeat top center; width:38px; height:19px; text-indent:-9999px;}
45 | #cboxClose:hover{background-position:bottom center;}
46 |
--------------------------------------------------------------------------------
/assets/components/structures/gallery/colorbox/images/controls.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/colorbox/images/controls.png
--------------------------------------------------------------------------------
/assets/components/structures/gallery/colorbox/images/light-controls.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/colorbox/images/light-controls.png
--------------------------------------------------------------------------------
/assets/components/structures/gallery/colorbox/images/loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/colorbox/images/loading.gif
--------------------------------------------------------------------------------
/assets/components/structures/gallery/images/loader.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/images/loader.gif
--------------------------------------------------------------------------------
/assets/components/structures/gallery/images/nature/Seaofclouds - 2880x1800.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/images/nature/Seaofclouds - 2880x1800.gif
--------------------------------------------------------------------------------
/assets/components/structures/gallery/images/nature/WatercolorSunsetHD.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/images/nature/WatercolorSunsetHD.gif
--------------------------------------------------------------------------------
/assets/components/structures/gallery/images/noImage.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/images/noImage.gif
--------------------------------------------------------------------------------
/assets/components/structures/gallery/js/download.js:
--------------------------------------------------------------------------------
1 | //download.js v3.0, by dandavis; 2008-2014. [CCBY2] see http://danml.com/download.html for tests/usage
2 | // v1 landed a FF+Chrome compat way of downloading strings to local un-named files, upgraded to use a hidden frame and optional mime
3 | // v2 added named files via a[download], msSaveBlob, IE (10+) support, and window.URL support for larger+faster saves than dataURLs
4 | // v3 added dataURL and Blob Input, bind-toggle arity, and legacy dataURL fallback was improved with force-download mime and base64 support
5 |
6 | // data can be a string, Blob, File, or dataURL
7 |
8 |
9 |
10 |
11 | function download(data, strFileName, strMimeType) {
12 |
13 | var self = window, // this script is only for browsers anyway...
14 | u = "application/octet-stream", // this default mime also triggers iframe downloads
15 | m = strMimeType || u,
16 | x = data,
17 | D = document,
18 | a = D.createElement("a"),
19 | z = function(a){return String(a);},
20 |
21 |
22 | B = self.Blob || self.MozBlob || self.WebKitBlob || z,
23 | BB = self.MSBlobBuilder || self.WebKitBlobBuilder || self.BlobBuilder,
24 | fn = strFileName || "download",
25 | blob,
26 | b,
27 | ua,
28 | fr;
29 |
30 | //if(typeof B.bind === 'function' ){ B=B.bind(self); }
31 |
32 | if(String(this)==="true"){ //reverse arguments, allowing download.bind(true, "text/xml", "export.xml") to act as a callback
33 | x=[x, m];
34 | m=x[0];
35 | x=x[1];
36 | }
37 |
38 |
39 |
40 | //go ahead and download dataURLs right away
41 | if(String(x).match(/^data\:[\w+\-]+\/[\w+\-]+[,;]/)){
42 | return navigator.msSaveBlob ? // IE10 can't do a[download], only Blobs:
43 | navigator.msSaveBlob(d2b(x), fn) :
44 | saver(x) ; // everyone else can save dataURLs un-processed
45 | }//end if dataURL passed?
46 |
47 | try{
48 |
49 | blob = x instanceof B ?
50 | x :
51 | new B([x], {type: m}) ;
52 | }catch(y){
53 | if(BB){
54 | b = new BB();
55 | b.append([x]);
56 | blob = b.getBlob(m); // the blob
57 | }
58 |
59 | }
60 |
61 |
62 |
63 | function d2b(u) {
64 | var p= u.split(/[:;,]/),
65 | t= p[1],
66 | dec= p[2] == "base64" ? atob : decodeURIComponent,
67 | bin= dec(p.pop()),
68 | mx= bin.length,
69 | i= 0,
70 | uia= new Uint8Array(mx);
71 |
72 | for(i;iinitialize('web'); //or mgr or any content you like
12 | $modx->getService('error','error.modError', '', '');
13 | if (!$modx->hasPermission('edit_chunk') || !$modx->hasPermission('edit_tv') || !$modx->hasPermission('file_upload')) {
14 | die("no permission");
15 | }
16 | if (isset($_GET['path']) && !empty($_GET['path'])) {
17 | $path = filter_var($_GET['path'], FILTER_SANITIZE_STRING);
18 | $path = rawurldecode($path);
19 | $inputedPath = $path;
20 | $autoCreateThumb = 0;
21 | $justJSON = 1;
22 | $options = 0;
23 | $doThumbs = 0;
24 | $thumbFld = "thumb/";
25 | if (isset($_GET['autoCreateThumb'], $_GET['justJSON']) && $_GET['autoCreateThumb'] == 1) {
26 | $autoCreateThumb = filter_var($_GET['autoCreateThumb'], FILTER_SANITIZE_STRING);
27 | $justJSON = filter_var($_GET['justJSON'], FILTER_SANITIZE_STRING);
28 | if (isset($_GET['options']) && !empty($_GET['options'])) {
29 | $options = filter_var($_GET['options'], FILTER_SANITIZE_STRING);
30 | }
31 | if (isset($_GET['doThumbs']) && $_GET['doThumbs'] == 1) {
32 | $doThumbs = filter_var($_GET['doThumbs'], FILTER_SANITIZE_STRING);
33 | }
34 | if (isset($_GET['thumbFldSuffix'])&& !empty($_GET['thumbFldSuffix'])) {
35 | $thumbFldSuffix = filter_var($_GET['thumbFldSuffix'], FILTER_SANITIZE_STRING);
36 | $thumbFld= "thumb" . $thumbFldSuffix . "/";
37 | }
38 | }
39 |
40 | function gallery($inputedPath, $autoCreateThumb, $justJSON, $options, $doThumbs, $thumbFld){
41 | global $modx;
42 | $optionsOri = $options;
43 | $partialOp = explode(',', $options);
44 | $optionsArray = array();
45 | array_walk($partialOp, function($val,$key) use(&$optionsArray){
46 | list($key, $value) = explode('=', $val);
47 | $optionsArray[$key] = $value;
48 | });
49 | $options = $optionsArray;
50 | //get inputedPath plus base, whether user has autoCreateThumb on or not
51 | $inputedFullPath = MODX_BASE_PATH . $inputedPath;
52 | //full url to full image
53 | $largeUrl = MODX_BASE_URL . $inputedPath;
54 | //full path to thumb image if autoCreateThumb is on
55 | $thumbPath = MODX_BASE_PATH . $inputedPath . $thumbFld;
56 | //full url to full image if autoCreateThumb is off, and user has own thumbs(must be child of parent folder :) )
57 | // $thumbParentUrl = dirname($largeUrl) . "/";
58 | $thumbParentUrl = $largeUrl;
59 | $thumbUrl = $thumbParentUrl . $thumbFld;
60 | $thumbInfo = $thumbReady = '';
61 | if ($autoCreateThumb == 1 && $options !== 0) {
62 | $thumbUrl = $largeUrl . $thumbFld;
63 | if ($justJSON == 0) {
64 | $thumbReady = 1;
65 | }
66 | }
67 |
68 | if (file_exists($inputedFullPath)) {
69 | // use Zebra
70 | // if ($autoCreateThumb && $justJSON == 0) {
71 | // if (!file_exists($thumbPath)) {
72 | // mkdir($thumbPath, 0777, true);
73 | // }
74 | // $checkResizer = 'Zebra_Image.php';
75 | // if (file_exists($checkResizer)) {
76 | // require 'Zebra_Image.php';
77 | // $resizer = new Zebra_Image();
78 | // }
79 | // if(!$resizer){
80 | // $thumbInfo = 'Zebra Image Resizer is needed to create thumbnails &justJSON was set to 0 - but no thumbs was created, only JSON ';
81 | // }
82 | // }
83 |
84 | //use resizer
85 | if ($autoCreateThumb && $justJSON == 0) {
86 | if (!file_exists($thumbPath)) {
87 | mkdir($thumbPath, 0777, true);
88 | }
89 | $checkResizer = MODX_CORE_PATH . 'components/resizer/model/';
90 | if (file_exists($checkResizer)) {
91 | $modx->loadClass('Resizer', MODX_CORE_PATH . 'components/resizer/model/', true, true);
92 | $resizer = new Resizer($modx);
93 | $resizer->debug = true;
94 | }
95 | if(!$resizer){
96 | $thumbInfo = 'MODX Resizer is needed to create thumbnails ';
97 | }
98 | }
99 | $images = glob($inputedFullPath . "*.{jpg,png,gif}", GLOB_BRACE);
100 | if ($images) {
101 | $comma = '';
102 | $output = "SCANNING: " . $inputedPath . " [";
103 | $output.= '{"Location": "' . $inputedPath . '&autoCreateThumb='.$autoCreateThumb.'&justJSON=1&options='.$optionsOri.'"}, '; //force justJSON to be 1 again to prevent user fro creating thumbs by mistake
104 | $index = 0;
105 | foreach ($images as $image) {
106 | $index ++;
107 | $timeStamp = filemtime($image);
108 | $image = pathinfo($image);
109 | $file = $image["filename"];
110 | $ext = $image["extension"];
111 | $fileExt = $file . "." . $ext;
112 | $thumbSrc = $thumbUrl . $fileExt;
113 | $thumbParentUrlFname = $thumbParentUrl . $fileExt;
114 | if ($justJSON == 0 && $autoCreateThumb == 1 && $options !== 0) {
115 | //use zebra
116 | // if($resizer){
117 | // // $resizer->processImage($inputedFullPath . $fileExt, $thumbPath . $fileExt, $options);
118 | // $resizer->source_path = $inputedFullPath . $fileExt;
119 | // $resizer->target_path = $thumbPath . $fileExt;
120 | // if (!$resizer->resize(178, 117, ZEBRA_IMAGE_BOXED, -1)) show_error($resizer->error, $resizer->source_path, $resizer->target_path);
121 | // $resizer->source_path = $thumbPath . $fileExt;
122 | // // if (!$resizer->crop(0, 0, 50, 50)) show_error($resizer->error, $resizer->source_path, $resizer->target_path);
123 | // // $resizer->crop(0, 0, 100, 100);
124 | // // $resizer->target_path = $thumbPath . $fileExt;
125 | // // $resizer->apply_filter(array(
126 | // // array('grayscale'),
127 | // // array('colorize', 90, 60, 40),
128 | // // ));
129 | // }
130 |
131 | //use resizer
132 | if($resizer){
133 | $resizer->processImage($inputedFullPath . $fileExt, $thumbPath . $fileExt, $options);
134 | }
135 | }
136 | $cleanfile = preg_replace('/[^A-Za-z0-9\-]/', ' ', $file);
137 | $output.= $comma . '{"id":"' . $file.'.'.$ext .'","title":"' . $file.'.'.$ext . '","folder":"' . $thumbParentUrl . '","hidden":"0","desc":"' . $cleanfile . '","index":"' . $index . '","tag":"","lerror":"0"}';
138 | $comma = ',';
139 | }
140 | if($thumbReady){
141 | $thumbInfo = "THUMBNAILS: " . $index . " thumb image(s) created in: " . $inputedPath . $thumbFld . " If any issues, check that the original images were not oversize";
142 | }
143 | $output.= "]
COPY CODE ABOVE and paste over your current JSON, and then press the option 'Build from Current JSON' ".$thumbInfo;
144 | if($doThumbs){
145 | return $thumbInfo;
146 | }
147 | else{
148 | return $output;
149 | }
150 | }
151 | else {
152 | return "No valid files (jpg,png,gif) in " . $inputedPath . "
";
153 | }
154 | }
155 | else {
156 | return "The folder " . $inputedPath . " does not exist
";
157 | }
158 | }
159 | echo '
160 |
161 |
162 |
165 |
166 |
167 | '.gallery($inputedPath, $autoCreateThumb, $justJSON, $options, $doThumbs, $thumbFld).'
168 |
169 | ';
170 | }
171 | else{
172 | die("Invalid ununderstandable non-human error");
173 | }
--------------------------------------------------------------------------------
/assets/components/structures/gallery/php/index.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/gallery/php/index.html
--------------------------------------------------------------------------------
/assets/components/structures/img/blank.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/img/blank.jpg
--------------------------------------------------------------------------------
/assets/components/structures/img/loader.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/img/loader.gif
--------------------------------------------------------------------------------
/assets/components/structures/js/structures_all.js:
--------------------------------------------------------------------------------
1 | /*!
2 | // donshakespeare @ MODX forums
3 | // https://github.com/donShakespeare
4 | // To God almighty be all glory*/
5 |
6 | //@koala-append "tinyBlocks.js"
7 | //@koala-append "../gallery/js/json2html.js"
8 | //@koala-append "../gallery/js/download.js"
9 | //@koala-append "../gallery/js/TinyJSONGallery.js"
--------------------------------------------------------------------------------
/assets/components/structures/markdown/Michelf/Markdown.inc.php:
--------------------------------------------------------------------------------
1 |
8 | #
9 | # Original Markdown
10 | # Copyright (c) 2004-2006 John Gruber
11 | #
12 | #
13 | namespace Michelf;
14 |
15 |
16 | #
17 | # Markdown Parser Interface
18 | #
19 |
20 | interface MarkdownInterface {
21 |
22 | #
23 | # Initialize the parser and return the result of its transform method.
24 | # This will work fine for derived classes too.
25 | #
26 | public static function defaultTransform($text);
27 |
28 | #
29 | # Main function. Performs some preprocessing on the input text
30 | # and pass it through the document gamut.
31 | #
32 | public function transform($text);
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/assets/components/structures/markdown/parsedown/ParsedownExtra.php:
--------------------------------------------------------------------------------
1 | BlockTypes[':'] []= 'DefinitionList';
32 | $this->BlockTypes['*'] []= 'Abbreviation';
33 |
34 | # identify footnote definitions before reference definitions
35 | array_unshift($this->BlockTypes['['], 'Footnote');
36 |
37 | # identify footnote markers before before links
38 | array_unshift($this->InlineTypes['['], 'FootnoteMarker');
39 | }
40 |
41 | #
42 | # ~
43 |
44 | function text($text)
45 | {
46 | $markup = parent::text($text);
47 |
48 | # merge consecutive dl elements
49 |
50 | $markup = preg_replace('/<\/dl>\s+\s+/', '', $markup);
51 |
52 | # add footnotes
53 |
54 | if (isset($this->DefinitionData['Footnote']))
55 | {
56 | $Element = $this->buildFootnoteElement();
57 |
58 | $markup .= "\n" . $this->element($Element);
59 | }
60 |
61 | return $markup;
62 | }
63 |
64 | #
65 | # Blocks
66 | #
67 |
68 | #
69 | # Abbreviation
70 |
71 | protected function blockAbbreviation($Line)
72 | {
73 | if (preg_match('/^\*\[(.+?)\]:[ ]*(.+?)[ ]*$/', $Line['text'], $matches))
74 | {
75 | $this->DefinitionData['Abbreviation'][$matches[1]] = $matches[2];
76 |
77 | $Block = array(
78 | 'hidden' => true,
79 | );
80 |
81 | return $Block;
82 | }
83 | }
84 |
85 | #
86 | # Footnote
87 |
88 | protected function blockFootnote($Line)
89 | {
90 | if (preg_match('/^\[\^(.+?)\]:[ ]?(.*)$/', $Line['text'], $matches))
91 | {
92 | $Block = array(
93 | 'label' => $matches[1],
94 | 'text' => $matches[2],
95 | 'hidden' => true,
96 | );
97 |
98 | return $Block;
99 | }
100 | }
101 |
102 | protected function blockFootnoteContinue($Line, $Block)
103 | {
104 | if ($Line['text'][0] === '[' and preg_match('/^\[\^(.+?)\]:/', $Line['text']))
105 | {
106 | return;
107 | }
108 |
109 | if (isset($Block['interrupted']))
110 | {
111 | if ($Line['indent'] >= 4)
112 | {
113 | $Block['text'] .= "\n\n" . $Line['text'];
114 |
115 | return $Block;
116 | }
117 | }
118 | else
119 | {
120 | $Block['text'] .= "\n" . $Line['text'];
121 |
122 | return $Block;
123 | }
124 | }
125 |
126 | protected function blockFootnoteComplete($Block)
127 | {
128 | $this->DefinitionData['Footnote'][$Block['label']] = array(
129 | 'text' => $Block['text'],
130 | 'count' => null,
131 | 'number' => null,
132 | );
133 |
134 | return $Block;
135 | }
136 |
137 | #
138 | # Definition List
139 |
140 | protected function blockDefinitionList($Line, $Block)
141 | {
142 | if ( ! isset($Block) or isset($Block['type']))
143 | {
144 | return;
145 | }
146 |
147 | $Element = array(
148 | 'name' => 'dl',
149 | 'handler' => 'elements',
150 | 'text' => array(),
151 | );
152 |
153 | $terms = explode("\n", $Block['element']['text']);
154 |
155 | foreach ($terms as $term)
156 | {
157 | $Element['text'] []= array(
158 | 'name' => 'dt',
159 | 'handler' => 'line',
160 | 'text' => $term,
161 | );
162 | }
163 |
164 | $Block['element'] = $Element;
165 |
166 | $Block = $this->addDdElement($Line, $Block);
167 |
168 | return $Block;
169 | }
170 |
171 | protected function blockDefinitionListContinue($Line, array $Block)
172 | {
173 | if ($Line['text'][0] === ':')
174 | {
175 | $Block = $this->addDdElement($Line, $Block);
176 |
177 | return $Block;
178 | }
179 | else
180 | {
181 | if (isset($Block['interrupted']) and $Line['indent'] === 0)
182 | {
183 | return;
184 | }
185 |
186 | if (isset($Block['interrupted']))
187 | {
188 | $Block['dd']['handler'] = 'text';
189 | $Block['dd']['text'] .= "\n\n";
190 |
191 | unset($Block['interrupted']);
192 | }
193 |
194 | $text = substr($Line['body'], min($Line['indent'], 4));
195 |
196 | $Block['dd']['text'] .= "\n" . $text;
197 |
198 | return $Block;
199 | }
200 | }
201 |
202 | #
203 | # Header
204 |
205 | protected function blockHeader($Line)
206 | {
207 | $Block = parent::blockHeader($Line);
208 |
209 | if (preg_match('/[ #]*{('.$this->regexAttribute.'+)}[ ]*$/', $Block['element']['text'], $matches, PREG_OFFSET_CAPTURE))
210 | {
211 | $attributeString = $matches[1][0];
212 |
213 | $Block['element']['attributes'] = $this->parseAttributeData($attributeString);
214 |
215 | $Block['element']['text'] = substr($Block['element']['text'], 0, $matches[0][1]);
216 | }
217 |
218 | return $Block;
219 | }
220 |
221 | #
222 | # Markup
223 |
224 | protected function blockMarkupComplete($Block)
225 | {
226 | if ( ! isset($Block['void']))
227 | {
228 | $Block['markup'] = $this->processTag($Block['markup']);
229 | }
230 |
231 | return $Block;
232 | }
233 |
234 | #
235 | # Setext
236 |
237 | protected function blockSetextHeader($Line, array $Block = null)
238 | {
239 | $Block = parent::blockSetextHeader($Line, $Block);
240 |
241 | if (preg_match('/[ ]*{('.$this->regexAttribute.'+)}[ ]*$/', $Block['element']['text'], $matches, PREG_OFFSET_CAPTURE))
242 | {
243 | $attributeString = $matches[1][0];
244 |
245 | $Block['element']['attributes'] = $this->parseAttributeData($attributeString);
246 |
247 | $Block['element']['text'] = substr($Block['element']['text'], 0, $matches[0][1]);
248 | }
249 |
250 | return $Block;
251 | }
252 |
253 | #
254 | # Inline Elements
255 | #
256 |
257 | #
258 | # Footnote Marker
259 |
260 | protected function inlineFootnoteMarker($Excerpt)
261 | {
262 | if (preg_match('/^\[\^(.+?)\]/', $Excerpt['text'], $matches))
263 | {
264 | $name = $matches[1];
265 |
266 | if ( ! isset($this->DefinitionData['Footnote'][$name]))
267 | {
268 | return;
269 | }
270 |
271 | $this->DefinitionData['Footnote'][$name]['count'] ++;
272 |
273 | if ( ! isset($this->DefinitionData['Footnote'][$name]['number']))
274 | {
275 | $this->DefinitionData['Footnote'][$name]['number'] = ++ $this->footnoteCount; # » &
276 | }
277 |
278 | $Element = array(
279 | 'name' => 'sup',
280 | 'attributes' => array('id' => 'fnref'.$this->DefinitionData['Footnote'][$name]['count'].':'.$name),
281 | 'handler' => 'element',
282 | 'text' => array(
283 | 'name' => 'a',
284 | 'attributes' => array('href' => '#fn:'.$name, 'class' => 'footnote-ref'),
285 | 'text' => $this->DefinitionData['Footnote'][$name]['number'],
286 | ),
287 | );
288 |
289 | return array(
290 | 'extent' => strlen($matches[0]),
291 | 'element' => $Element,
292 | );
293 | }
294 | }
295 |
296 | private $footnoteCount = 0;
297 |
298 | #
299 | # Link
300 |
301 | protected function inlineLink($Excerpt)
302 | {
303 | $Link = parent::inlineLink($Excerpt);
304 |
305 | $remainder = substr($Excerpt['text'], $Link['extent']);
306 |
307 | if (preg_match('/^[ ]*{('.$this->regexAttribute.'+)}/', $remainder, $matches))
308 | {
309 | $Link['element']['attributes'] += $this->parseAttributeData($matches[1]);
310 |
311 | $Link['extent'] += strlen($matches[0]);
312 | }
313 |
314 | return $Link;
315 | }
316 |
317 | #
318 | # ~
319 | #
320 |
321 | protected function unmarkedText($text)
322 | {
323 | $text = parent::unmarkedText($text);
324 |
325 | if (isset($this->DefinitionData['Abbreviation']))
326 | {
327 | foreach ($this->DefinitionData['Abbreviation'] as $abbreviation => $meaning)
328 | {
329 | $pattern = '/\b'.preg_quote($abbreviation, '/').'\b/';
330 |
331 | $text = preg_replace($pattern, ''.$abbreviation.' ', $text);
332 | }
333 | }
334 |
335 | return $text;
336 | }
337 |
338 | #
339 | # Util Methods
340 | #
341 |
342 | protected function addDdElement(array $Line, array $Block)
343 | {
344 | $text = substr($Line['text'], 1);
345 | $text = trim($text);
346 |
347 | unset($Block['dd']);
348 |
349 | $Block['dd'] = array(
350 | 'name' => 'dd',
351 | 'handler' => 'line',
352 | 'text' => $text,
353 | );
354 |
355 | if (isset($Block['interrupted']))
356 | {
357 | $Block['dd']['handler'] = 'text';
358 |
359 | unset($Block['interrupted']);
360 | }
361 |
362 | $Block['element']['text'] []= & $Block['dd'];
363 |
364 | return $Block;
365 | }
366 |
367 | protected function buildFootnoteElement()
368 | {
369 | $Element = array(
370 | 'name' => 'div',
371 | 'attributes' => array('class' => 'footnotes'),
372 | 'handler' => 'elements',
373 | 'text' => array(
374 | array(
375 | 'name' => 'hr',
376 | ),
377 | array(
378 | 'name' => 'ol',
379 | 'handler' => 'elements',
380 | 'text' => array(),
381 | ),
382 | ),
383 | );
384 |
385 | uasort($this->DefinitionData['Footnote'], 'self::sortFootnotes');
386 |
387 | foreach ($this->DefinitionData['Footnote'] as $definitionId => $DefinitionData)
388 | {
389 | if ( ! isset($DefinitionData['number']))
390 | {
391 | continue;
392 | }
393 |
394 | $text = $DefinitionData['text'];
395 |
396 | $text = parent::text($text);
397 |
398 | $numbers = range(1, $DefinitionData['count']);
399 |
400 | $backLinksMarkup = '';
401 |
402 | foreach ($numbers as $number)
403 | {
404 | $backLinksMarkup .= ' ';
405 | }
406 |
407 | $backLinksMarkup = substr($backLinksMarkup, 1);
408 |
409 | if (substr($text, - 4) === '')
410 | {
411 | $backLinksMarkup = ' '.$backLinksMarkup;
412 |
413 | $text = substr_replace($text, $backLinksMarkup.'', - 4);
414 | }
415 | else
416 | {
417 | $text .= "\n".''.$backLinksMarkup.'
';
418 | }
419 |
420 | $Element['text'][1]['text'] []= array(
421 | 'name' => 'li',
422 | 'attributes' => array('id' => 'fn:'.$definitionId),
423 | 'text' => "\n".$text."\n",
424 | );
425 | }
426 |
427 | return $Element;
428 | }
429 |
430 | # ~
431 |
432 | protected function parseAttributeData($attributeString)
433 | {
434 | $Data = array();
435 |
436 | $attributes = preg_split('/[ ]+/', $attributeString, - 1, PREG_SPLIT_NO_EMPTY);
437 |
438 | foreach ($attributes as $attribute)
439 | {
440 | if ($attribute[0] === '#')
441 | {
442 | $Data['id'] = substr($attribute, 1);
443 | }
444 | else # "."
445 | {
446 | $classes []= substr($attribute, 1);
447 | }
448 | }
449 |
450 | if (isset($classes))
451 | {
452 | $Data['class'] = implode(' ', $classes);
453 | }
454 |
455 | return $Data;
456 | }
457 |
458 | # ~
459 |
460 | protected function processTag($elementMarkup) # recursive
461 | {
462 | # http://stackoverflow.com/q/1148928/200145
463 | libxml_use_internal_errors(true);
464 |
465 | $DOMDocument = new DOMDocument;
466 |
467 | # http://stackoverflow.com/q/11309194/200145
468 | $elementMarkup = mb_convert_encoding($elementMarkup, 'HTML-ENTITIES', 'UTF-8');
469 |
470 | # http://stackoverflow.com/q/4879946/200145
471 | $DOMDocument->loadHTML($elementMarkup);
472 | $DOMDocument->removeChild($DOMDocument->doctype);
473 | $DOMDocument->replaceChild($DOMDocument->firstChild->firstChild->firstChild, $DOMDocument->firstChild);
474 |
475 | $elementText = '';
476 |
477 | if ($DOMDocument->documentElement->getAttribute('markdown') === '1')
478 | {
479 | foreach ($DOMDocument->documentElement->childNodes as $Node)
480 | {
481 | $elementText .= $DOMDocument->saveHTML($Node);
482 | }
483 |
484 | $DOMDocument->documentElement->removeAttribute('markdown');
485 |
486 | $elementText = "\n".$this->text($elementText)."\n";
487 | }
488 | else
489 | {
490 | foreach ($DOMDocument->documentElement->childNodes as $Node)
491 | {
492 | $nodeMarkup = $DOMDocument->saveHTML($Node);
493 |
494 | if ($Node instanceof DOMElement and ! in_array($Node->nodeName, $this->textLevelElements))
495 | {
496 | $elementText .= $this->processTag($nodeMarkup);
497 | }
498 | else
499 | {
500 | $elementText .= $nodeMarkup;
501 | }
502 | }
503 | }
504 |
505 | # because we don't want for markup to get encoded
506 | $DOMDocument->documentElement->nodeValue = 'placeholder\x1A';
507 |
508 | $markup = $DOMDocument->saveHTML($DOMDocument->documentElement);
509 | $markup = str_replace('placeholder\x1A', $elementText, $markup);
510 |
511 | return $markup;
512 | }
513 |
514 | # ~
515 |
516 | protected function sortFootnotes($A, $B) # callback
517 | {
518 | return $A['number'] - $B['number'];
519 | }
520 |
521 | #
522 | # Fields
523 | #
524 |
525 | protected $regexAttribute = '(?:[#.][-\w]+[ ]*)';
526 | }
--------------------------------------------------------------------------------
/assets/components/structures/rapidimage/tinyBlocksRapidImage.php:
--------------------------------------------------------------------------------
1 | $filetowrite));
75 | echo json_encode(array('location' => $uploadUrl . $temp['name']));
76 | } else {
77 | // Notify editor that the upload failed
78 | header("HTTP/1.0 500 Server Error");
79 | }
80 | ?>
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/Variables.less:
--------------------------------------------------------------------------------
1 | // Variables
2 | // Syntax: -()--()-();
3 | // Example: @btn-primary-bg-hover-hlight;
4 |
5 | @prefix: mce;
6 |
7 | // Default font
8 | @font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
9 | @font-size: 14px;
10 | @line-height: 20px;
11 | @has-gradients: false;
12 | @has-radius: false;
13 | @has-boxshadow: false;
14 | @has-button-borders: true;
15 |
16 | // Text colors
17 | @text: #ffffff;
18 | @text-inverse: #000000;
19 | @text-disabled: #ffffff;
20 | @text-shadow: 0 1px 1px hsla(hue(@text-inverse), saturation(@text-inverse), lightness(@text-inverse), 0.75);
21 | @text-error: #aa0000;
22 |
23 | // Button
24 | @btn-text: #dedede;
25 | @btn-text-shadow: #000000;
26 | @btn-border-top: rgba(0,0,0,0);
27 | @btn-border-right: rgba(0,0,0,0);
28 | @btn-border-bottom: rgba(0,0,0,0);
29 | @btn-border-left: rgba(0,0,0,0);
30 | @btn-caret-border: @btn-text;
31 | @btn-text-disabled: @text-disabled;
32 | @btn-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 1px 2px rgba(0, 0, 0, .05);
33 | @btn-box-shadow-active: inset 0 2px 4px rgba(0, 0, 0, .15), 0 1px 2px rgba(0, 0, 0, .05);
34 | @btn-box-disabled-opacity: 0.4;
35 | @btn-bg: #303942;
36 | @btn-bg-hlight: #292929;
37 | @btn-bg-hover: darken(@btn-bg, 5%);
38 | @btn-bg-hlight-hover: darken(@btn-bg-hlight, 5%);
39 | @btn-border-hover: darken(@btn-bg, 20%);
40 | @btn-border-active: darken(@btn-bg, 20%);
41 | @btn-padding: 4px 8px;
42 |
43 | @btn-primary-bg: #000000;
44 | @btn-primary-bg-hlight: #1f1f1f;
45 | @btn-primary-bg-hover: darken(@btn-primary-bg, 5%);
46 | @btn-primary-bg-hover-hlight: darken(@btn-primary-bg-hlight, 5%);
47 | @btn-primary-text: #ffffff;
48 | @btn-primary-text-shadow: #000000;
49 | @btn-primary-border-top: mix(@btn-border-top, @btn-primary-bg, 50%);
50 | @btn-primary-border-right: mix(@btn-border-right, @btn-primary-bg, 50%);
51 | @btn-primary-border-bottom: mix(@btn-border-bottom, @btn-primary-bg, 50%);
52 | @btn-primary-border-left: mix(@btn-border-left, @btn-primary-bg, 50%);
53 | @btn-primary-border: transparent;
54 | @btn-primary-border-hover: transparent;
55 |
56 | // Button group
57 | @btn-group-border-width: 1px;
58 |
59 | // Menu
60 | @menuitem-text: #dddddd;
61 | @menu-bg: #303942;
62 | @menu-margin: -1px 0 0;
63 | @menu-border: #25313f;
64 | @menubar-border: mix(@panel-border, @panel-bg, 60%);
65 | @menuitem-text-inverse: #ffffff;
66 | @menubar-bg-active: darken(@btn-bg, 10%);
67 | @menuitem-bg-hover: #0081C2;
68 | @menuitem-bg-selected: #6b7e87;
69 | @menuitem-bg-selected-hlight: #222629;
70 | @menuitem-bg-disabled: #CCC;
71 | @menuitem-caret: @menuitem-text;
72 | @menuitem-caret-selected: @menuitem-text-inverse;
73 | @menuitem-separator-top: #25313f;
74 | @menuitem-separator-bottom: #424f5f;
75 | @menuitem-bg-active: #395461;
76 | @menuitem-text-active: #ffffff;
77 | @menuitem-preview-border-active: #dedede;
78 | @menubar-menubtn-text: #b5b9bf;
79 |
80 | // Panel
81 | @panel-border: #303942;
82 | @panel-bg: #303942;
83 | @panel-bg-hlight: #000000;
84 |
85 | // Tabs
86 | @tab-border: #202a33;
87 | @tab-bg: #303942;
88 | @tab-bg-hover: #404952;
89 | @tab-bg-active: #404952;
90 | @tabs-bg: #303942;
91 |
92 | // Tooltip
93 | @tooltip-bg: #000;
94 | @tooltip-text: white;
95 | @tooltip-font-size: 11px;
96 |
97 | // Notification
98 | @notification-font-size: 14px;
99 | @notification-bg: #f0f0f0;
100 | @notification-border: #cccccc;
101 | @notification-text: #333333;
102 | @notification-success-bg: #dff0d8;
103 | @notification-success-border: #d6e9c6;
104 | @notification-success-text: #3c763d;
105 | @notification-info-bg: #d9edf7;
106 | @notification-info-border: #779ecb;
107 | @notification-info-text: #31708f;
108 | @notification-warning-bg: #fcf8e3;
109 | @notification-warning-border: #faebcc;
110 | @notification-warning-text: #8a6d3b;
111 | @notification-error-bg: #f2dede;
112 | @notification-error-border: #ebccd1;
113 | @notification-error-text: #a94442;
114 |
115 | // Window
116 | @window-border: #9e9e9e;
117 | @window-head-border: @window-border;
118 | @window-head-close: mix(@text, @window-bg, 60%);
119 | @window-head-close-hover: mix(@text, @window-bg, 40%);
120 | @window-foot-border: @window-border;
121 | @window-foot-bg: @window-bg;
122 | @window-fullscreen-bg: #FFF;
123 | @window-modalblock-bg: #000;
124 | @window-modalblock-opacity: 0.3;
125 | @window-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3);
126 | @window-bg: #404952;
127 | @window-title-font-size: 20px;
128 |
129 | // Popover
130 | @popover-bg: @window-bg;
131 | @popover-arrow-width: 10px;
132 | @popover-arrow: @window-bg;
133 | @popover-arrow-outer-width: @popover-arrow-width + 1;
134 | @popover-arrow-outer: rgba(0, 0, 0, 0.25);
135 |
136 | // Floatpanel
137 | @floatpanel-box-shadow: 0 5px 10px rgba(0, 0, 0, .2);
138 |
139 | // Checkbox
140 | @checkbox-bg: @btn-bg;
141 | @checkbox-bg-hlight: @btn-bg-hlight;
142 | @checkbox-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 1px 2px rgba(0, 0, 0, .05);
143 | @checkbox-border: #202a33;
144 | @checkbox-border-focus: #979a9c;
145 |
146 | // Path
147 | @path-text: @text;
148 | @path-bg-focus: #666;
149 | @path-text-focus: #fff;
150 |
151 | // Textbox
152 | @textbox-text-placeholder: #aaa;
153 | @textbox-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
154 | @textbox-bg: #515c67;
155 | @textbox-border: #202a33;
156 | @textbox-border-focus: #242e33;
157 |
158 | // Selectbox
159 | @selectbox-bg: @textbox-bg;
160 | @selectbox-border: @textbox-border;
161 |
162 | // Throbber
163 | @throbber-bg: #fff url('img/loader.gif') no-repeat center center;
164 |
165 | // Combobox
166 | @combobox-border: @textbox-border;
167 |
168 | // Colorpicker
169 | @colorpicker-border: @textbox-border;
170 | @colorpicker-hue-bg: #fff;
171 | @colorpicker-hue-border: #333;
172 |
173 | // Grid
174 | @grid-bg-active: @menuitem-bg-active;
175 | @grid-border-active: #d6d6d6;
176 | @grid-border: #d6d6d6;
177 |
178 | // Misc
179 | @colorbtn-backcolor-bg: #384552;
180 | @iframe-border: @panel-border;
181 |
182 | // Slider
183 | @slider-border: #202a33;
184 | @slider-bg: #515c67;
185 | @slider-handle-border: #000000;
186 | @slider-handle-bg: #454f59;
187 |
188 | // Progress
189 | @progress-border: #202a33;
190 | @progress-bar-bg: #515c67;
191 | @progress-bar-bg-hlight: #515c67;
192 | @progress-text: #c4c4c4;
193 | @progress-text-shadow: #000000;
194 |
195 | // Flow layout
196 | @flow-layout-spacing: 2px;
197 |
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/content.inline.min.css:
--------------------------------------------------------------------------------
1 | .mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected="2"] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/content.min.css:
--------------------------------------------------------------------------------
1 | body{background-color:#fff;color:#000;font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px;scrollbar-3dlight-color:#f0f0ee;scrollbar-arrow-color:#676662;scrollbar-base-color:#f0f0ee;scrollbar-darkshadow-color:#ddd;scrollbar-face-color:#e0e0dd;scrollbar-highlight-color:#f0f0ee;scrollbar-shadow-color:#f0f0ee;scrollbar-track-color:#f5f5f5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected="2"] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/readme.md:
--------------------------------------------------------------------------------
1 | Icons are generated and provided by the http://icomoon.io service.
2 |
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.eot
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.ttf
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce-small.woff
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.eot
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.ttf
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/fonts/tinymce.woff
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/img/anchor.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/img/anchor.gif
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/img/loader.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/img/loader.gif
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/img/object.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/img/object.gif
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/img/trans.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/tinymceskins/hamlet/img/trans.gif
--------------------------------------------------------------------------------
/assets/components/structures/tinymceskins/hamlet/skin.json:
--------------------------------------------------------------------------------
1 | {
2 | "skin-name": "hamlet-plain",
3 | "preview-bg": "#ffffff",
4 | "text": "#ffffff",
5 | "text-inverse": "#000000",
6 | "text-disabled": "#ffffff",
7 | "has-gradients": false,
8 | "has-radius": false,
9 | "has-boxshadow": false,
10 | "has-button-borders": true,
11 | "btn-text": "#dedede",
12 | "btn-text-shadow": "#000000",
13 | "btn-bg": "#303942",
14 | "btn-bg-hlight": "#292929",
15 | "btn-border-top": "rgba(0,0,0,0)",
16 | "btn-border-right": "rgba(0,0,0,0)",
17 | "btn-border-bottom": "rgba(0,0,0,0)",
18 | "btn-border-left": "rgba(0,0,0,0)",
19 | "btn-split-border": "#ffffff",
20 | "btn-primary-text": "#ffffff",
21 | "btn-primary-text-shadow": "#000000",
22 | "btn-primary-bg": "#000000",
23 | "btn-primary-bg-hlight": "#1f1f1f",
24 | "btn-padding": "4px 8px",
25 | "menu-bg": "#303942",
26 | "menu-border": "#25313f",
27 | "menuitem-text": "#dddddd",
28 | "menuitem-bg-selected": "#6b7e87",
29 | "menuitem-bg-selected-hlight": "#222629",
30 | "menuitem-separator-top": "#25313f",
31 | "menuitem-separator-bottom": "#424f5f",
32 | "menuitem-text-inverse": "#ffffff",
33 | "menuitem-bg-active": "#395461",
34 | "menuitem-text-active": "#ffffff",
35 | "menuitem-preview-border-active": "#dedede",
36 | "menubar-menubtn-text": "#b5b9bf",
37 | "checkbox-border": "#202a33",
38 | "checkbox-border-focus": "#979a9c",
39 | "panel-border": "#303942",
40 | "panel-bg": "#303942",
41 | "panel-bg-hlight": "#000000",
42 | "textbox-bg": "#515c67",
43 | "textbox-border": "#202a33",
44 | "textbox-border-focus": "#242e33",
45 | "window-bg": "#404952",
46 | "window-border": "#9e9e9e",
47 | "tab-bg": "#303942",
48 | "tab-bg-hover": "#404952",
49 | "tab-bg-active": "#404952",
50 | "tab-border": "#202a33",
51 | "tabs-bg": "#303942",
52 | "notification-bg": "#f0f0f0",
53 | "notification-border": "#cccccc",
54 | "notification-text": "#333333",
55 | "notification-success-bg": "#dff0d8",
56 | "notification-success-border": "#d6e9c6",
57 | "notification-success-text": "#3c763d",
58 | "notification-info-bg": "#d9edf7",
59 | "notification-info-border": "#779ecb",
60 | "notification-info-text": "#31708f",
61 | "notification-warning-bg": "#fcf8e3",
62 | "notification-warning-border": "#faebcc",
63 | "notification-warning-text": "#8a6d3b",
64 | "notification-error-bg": "#f2dede",
65 | "notification-error-border": "#ebccd1",
66 | "notification-error-text": "#a94442",
67 | "progress-bar-bg": "#515c67",
68 | "progress-bar-bg-hlight": "#515c67",
69 | "progress-border": "#202a33",
70 | "progress-text": "#c4c4c4",
71 | "progress-text-shadow": "#000000",
72 | "slider-bg": "#515c67",
73 | "slider-border": "#202a33",
74 | "slider-handle-bg": "#454f59",
75 | "slider-handle-border": "#000000",
76 | "colorbtn-backcolor-bg": "#384552",
77 | "grid-border": "#d6d6d6",
78 | "grid-border-active": "#d6d6d6"
79 | }
--------------------------------------------------------------------------------
/assets/components/structures/uploads/blank.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/donShakespeare/Structures/ed35bc934def647ffb1a6cb4f33067c4ea431f43/assets/components/structures/uploads/blank.png
--------------------------------------------------------------------------------
/core/components/structures/docs/changelog.txt:
--------------------------------------------------------------------------------
1 | Changelog file for Structures extra.
2 | https://github.com/donShakespeare/Structures/blob/master/core/components/structures/docs/changelog.txt
3 |
4 | # Structures 3.1.0-beta1 (November 20, 2016)
5 | =======================================
6 |
7 | # List of exciting new features
8 |
9 | + RESTORE STRUCTURES CONTENT
10 | - Restore from Original content
11 | - Restore from Last Saved
12 |
13 | + TEMPLATE VARIABLES
14 | - ADDDED *structuresTV_ids* to Template Properties
15 | Takes comma-separated list of ids of TVs to bind to Structures. Two Modes:
16 | 1) 12,13,14,15 ... (choose Editors on the fly)
17 | 2) 12*richtext, 13*markdown, 14*markdown, 15*richtext ... (predetermined structure/editors)
18 | Supported TV xtypes: Hidden, Textarea, Text
19 | Say byebye to the TV tab altogether
20 | - ADDED optional to *st.save_buttons* chunk
21 | access TVs from each block menu, Structures main menu, or dedicated TV list menu
22 |
23 | + STRUCTURES GALLERY
24 | - ADDED full support for TV xtype: Hidden (sweeeeet!)
25 | - UI clean up
26 |
27 | + STRUCTURES CONTENT ENVIRONMENT
28 | - ADDED spellcheck attribute on body
29 | - REMOVED external dash border: replaced with click-to-blur-structures functionality
30 | - REVERTED back to more stable version of twExoticMarkdownEditor.js(v1)
31 | - FIXED Structures Tree in Firefox
32 | - DISABLED selectable in nested structures
33 |
34 | + TO DO
35 | - Fix silly Ace conflict
36 |
37 |
38 |
39 | # Structures 3.0.0-beta1 (November 8, 2016)
40 | =======================================
41 | Hi, I am Structures 3.0 - your best Content Building Tool. And I am only three months old!
42 |
43 | # List of exciting new features
44 |
45 | + SUPERB GALLERY FUNCTIONALITY
46 | - one click, create gallery from File Browser
47 | - one click, create gallery from File Tree
48 | - one click, create gallery directly from Server
49 | - you can attach a main gallery to current Resource via your TV (xtype: textarea, text, [avoid hidden xtype for now])
50 | - you can attach a gallery to each block/structure via chunk from Element Tree by means of block Title tv22, ch43
51 | - The onboard Gallery Manager can create real physical thumbnails for you at designated places with all kinds of size settings. /Yourfolder/thumb/ andOr /Yourfolder/thumb200x100/ andOr /Yourfolder/thumb200/ etc
52 | - The Gallery can produce unlimited patterns of HTML output to fit your frontend plugins
53 |
54 | + STRUCTURES NEW BEHAVIOUR
55 | - ADDED replacement to getChunk in Structures Plugin - 50% boost in speed. Note! MODX tags in *st_structures* chunk are preserved and not rendered, so is the case with many other chunks
56 | - ADDED Structures Menu button, commented out the old buttons next to MODX Save/Duplicate etc buttons
57 | In *st.save_buttons* chunk find ` `
58 | To add a Gallery button for your client, just uncomment it in that chunk
59 |
60 | - ADDED ability to use Structures without creating extra TABS in your Resource Content (sweeeeeeet!)
61 | This was possible only for Element Tree by specifying *sidebar_tab_title* to hidden
62 | Now you can specify *content_tab_title* to hidden, and Structures will use your original Content Area instead (how about that huh!?!!)
63 |
64 | - ADDED new Structure/block: Nested Structures! (nesting is now supported - ideal for whatever).
65 |
66 | - ADDED MarkdownE as default Markdown parser for Structures Snippet, instead of the ParsedownE. Structures Snippet classnames cleanup is highly rustic at this time.
67 |
68 | - CHANGES to Template Properties
69 | Renamed customPset to StructuresCustomPset
70 | *standByStructure* : use this to provide a default structure editor to show when Resource Content is empty. Note! this will replace that HELP content that shows by default
71 | *defaultGalleryTVid* : you can now bind a Resource TV to your Structures Gallery Manager (kbd = g + t)
72 | *randomTips* : provide random tips for your clients to show per page-reload in Structures tree, and to pop it use (kbd = r + t)
73 | - ADDED some new keyboard shortcuts: for gallery, random tip etc etc
74 | - Experimentally removed default shrinking of structures/blocks on page load (tell me if you don't like it)
75 |
76 |
77 | + CLEAN UP (MODX Elements and Assets Files)
78 | - REMOVED Slate and Lector Templates - with all respective belongings (now just Structures Template): these themes, as all other templates and thirdparty plugins, will ship independently - so roll your sleeves and start contributing!!!
79 |
80 | - REMOVED all classname options from Template Property (but if you add them manually, the custom options will be respected)
81 |
82 | - RENAMED TV StructuresCMR to Structures
83 |
84 | - CONCATENATED AND MINIFIED all essential JS and CSS files.
85 | Final JS file is *structures_all.min.js* ... please build yours for advanced usage
86 | Final CSS file is *structures_all.min.css*
87 | tinymce_plugins.js rightfully renamed to donshakepeare_tinymce.min.js (please build yours from github.com/donShakespeare/)
88 |
89 |
90 | + TINYMCE UBERNESS
91 | - New Official Structures skin: Hamlet, the Lovable!
92 | - Updated and reworked most of my TinyMCE plugins (find them at github.com/donShakespeare/)
93 | - Features tinymceBubbleBar 2.0 with multiple floating toolbars: Selection and New Line toolbars (for both RTE and MDE)
94 |
95 | + And the rest history
96 |
97 |
98 | # Structures 2.0.0-beta2 (September 18, 2016)
99 | =======================================
100 | The first release was a mere teaser. Folks, welcome to Structures - one month old!
101 |
102 | # List of exciting features
103 |
104 | + Ability to use Structures to do exactly what you used to do before (new feature - pureContent)
105 | + Complete intuitive Keyboard shortcut control
106 | + Addition of two new brilliant themes: Lector and Slate
107 | + Support for ANY HTML Markup (with refined simplicity)
108 | + Click or Drag n' Drop from Structures Tree into content
109 | + Smooth and sleek sorting.
110 | + Single/Multiple selecting of structures - for rapid management
111 | + Selective or Complete Clear All
112 | + Each structure can now have a title
113 |
114 | # Beyond Awesome
115 |
116 | + *Ace* with all its power has been introduced to cater for Markdown syntax highlighting.
117 | + *Auto Import* of any content to be broken up into several structures or simply compiled into one. Do it manually, or simply open the resource (auto structured and saved) ... voila!
118 | + *Auto Upload on Image Data Paste or Drag n' Drop* this is pure awesome, period! From clipboard to server in milliseconds ...
119 |
120 |
121 | # Roadmap
122 |
123 | + Search/categorize structures - with goto/sendto functionality
124 | + Complete frontend solution
125 | + Detail github wiki page
126 | + Create more fantastic themes for MODX - powered by Structures
127 | + Create ready-made chunks of HTML structures and editor settings
128 | + Utilize the power of PHP domdocument in snippet
129 | + Extend Markdown Parser
130 |
131 |
132 | # Structures 1.0.0-beta (August 9, 2016)
133 | =======================================
134 |
135 | - Initial release
136 |
--------------------------------------------------------------------------------
/core/components/structures/docs/readme.txt:
--------------------------------------------------------------------------------
1 | Structures Extra for MODX Revolution
2 | =======================================
3 |
4 | https://github.com/donShakespeare/Structures
5 |
6 | A fantastic new way to handle content in MODX.
7 |
--------------------------------------------------------------------------------
/core/components/structures/docs/tutorial.html:
--------------------------------------------------------------------------------
1 | See https://github.com/donShakespeare/Structures/wiki
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.ace_mirror_config.chunk.html:
--------------------------------------------------------------------------------
1 | st_aceInnerInit = function() {
2 | var inner = {
3 | maxLines: Infinity,
4 | mode: "ace/mode/markdown",
5 | wrap: "free",
6 | showPrintMargin: false,
7 | displayIndentGuides :true,
8 | highlightActiveLine : false,
9 | showGutter : false,
10 | fontSize: 15,
11 | tabSize: 2,
12 | useWorker: false
13 | }
14 | return inner;
15 | };
16 |
17 |
18 | var aceTempDiv =
19 | $('', {
20 | 'id': 'ace_wrapper_'+originalTextareaId,
21 | 'class': 'ace_wrapper_modx tinyBlocksCE',
22 | 'data-ace': 'ace_id_'+originalTextareaId,
23 | 'data-origin': originalTextareaId,
24 | 'data-mode': "markdown",
25 | 'data-maxL': "Infinity",
26 | 'data-wrap': "free"
27 | }).prepend(
28 | // $('
', {
29 | // 'class': 'aceKitchenSink',
30 | // 'text': "markdown"
31 | // }),
32 | $('', {
33 | 'id': 'ace_id_'+ originalTextareaId,
34 | 'width': "auto",
35 | 'data-origin': originalTextareaId
36 | })
37 | ).hide().insertBefore($("#"+originalTextareaId));
38 | if($("#"+originalTextareaId)[0].parentNode.nodeName == "PRE" || $("#"+originalTextareaId)[0].parentNode.nodeName == "CODE"){
39 | var tag = "Code";
40 | }
41 | else{
42 | var tag = "MD";
43 | }
44 | $("#"+originalTextareaId).parents(".tinyBlocksRowTempHolderClass").find(".tb-name").html(tag).attr("Powered by Ace");
45 | var aceEditor = ace.edit("ace_id_"+ originalTextareaId);
46 | aceEditor.$blockScrolling = Infinity;
47 | aceEditor.setOptions(st_aceInnerInit());
48 | // aceEditor.renderer.setShowGutter(false);
49 | // aceEditor.setHighlightActiveLine(false);
50 | aceEditor.getSession().setValue(document.getElementById(originalTextareaId).value);
51 | $('#ace_wrapper_'+originalTextareaId).delay(100).fadeIn();
52 | aceEditor.on("change",function(){
53 | document.getElementById(originalTextareaId).value = aceEditor.getValue();
54 | });
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.help_howto.chunk.html:
--------------------------------------------------------------------------------
1 |
2 |
Structures Content Area
3 |
4 | Blur Structures to activate keyboard shortcuts; use esc key or click outside Structures' environment (grey area)
5 | Click or drag a structure title from the Structures Tree or use keys 1 through 9 - use alt to extend beyond 9
6 | Rearrange your structures by dragging its Index Number (on the left) or use up and down arrow keys
7 | Click the same Index Number to select/deselect a structure
8 | Double-click same Index Number to select/deselect all structures, or use a
9 | Click outside structures and drag across single or multiple structures to select them
10 | Click top of structure to enter a title (t) - or use the Drop Arrow button next to the Index Number
11 | To associate a Chunk (from element tree) or loaded resource TV, simply add - TV23 or CH23 to the title of your inserted structure, then run "Gallery" (g + 1) from your menu button
12 |
13 |
14 |
Drop Arrow Button
15 |
This button appears upon hover of each row, and thus signifies the active structure to which its menu is referring
16 |
If there is only one structure this button becomes absent, but its functions can still be keyboarded
17 |
18 |
Structures Main Menu / Save Buttons
19 |
Delete can also delete only selected structures. It defaults to permanently removing all structures from the face of the planet
20 |
Import : you will see your existing content in the source (s ) textarea, or paste fresh content. Make sure your content contains the official Structures MODX comment tags, that is, [[-STRUCTURES]] or [[-STRUCTURES-SINGLE]]
21 | - Paste [[-STRUCTURES-SINGLE]] for only one block.
22 | - Paste [[-STRUCTURES]] as many times where you want your content to be broken into blocks
23 | When ready, hit Import (i + m )
24 | NOTE! Structures uses the HTML in your st.importWrapper_tpl and st.importMarker_tpl chunks to decide what kind of editor to use
25 | You may automatically accomplish this process of import/save resource by carefully selecting the import options in your Template's properties
26 |
Keyboard Shortcuts
27 |
28 | esc = Blur all Editors (or click outside) to activate Shortcuts
29 | ctrl + s = Save Resource
30 | ctrl + l.click = insert P in difficult areas of RTE
31 | b = Debug (shows structures detail in sidebar)
32 | h = Help / How-to Modal Window
33 | home = Toggle Distraction-free Mode
34 | up / down arrows = Move "this structure"
35 | c = Duplicate "this structure"
36 | del + 1 = Delete "this structure"
37 | del + a = Delete All/Selected structure(s)
38 | - / + = Shrink / Expand all structure(s)
39 | 0 = Total Count number of inserted structures
40 | a = Select all structures
41 | 1 through 9 = Quick Insert of first NINE HTML template structures
42 | alt + single/double digits = Extends beyond first 9. Also, when a Rich Text Editor has focus, inserted structure becomes embedded
43 | s = Content Source and Import Manager
44 | i + m = To actually import/convert
45 | t = Enter title for "this structure" - add ch23 or tv23 to associate a gallery
46 | g + 1 = Activate gallery for "this structure"
47 | g + g = Activate Global Gallery (after which you can dblclick any Resource TV or any quick-updated Chunk from Element Tree
48 | g + t = Activate Default TV Gallery - of TV prespecified in Template Properties
49 | d = Disable Structures temporarily for this resource
50 | r + t = Quick Random Tip (per page load)
51 |
52 |
Yours imaginatively, donShakespearehttps://github.com/donShakespeare/Structures
53 |
54 |
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.importmarker_tpl.chunk.html:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.importwrapper_tpl.chunk.html:
--------------------------------------------------------------------------------
1 |
[[+content]]
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.save_buttons.chunk.html:
--------------------------------------------------------------------------------
1 |
14 |
15 |
16 |
17 |
18 |
Save
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.structures.chunk.html:
--------------------------------------------------------------------------------
1 |
23 |
24 |
25 |
26 |
27 | Ace Markdown
28 | Ace Markdown
29 |
30 |
31 |
32 | Markdown
33 | Markdown
34 |
35 |
36 |
37 | Rich Text
38 |
39 |
40 |
41 |
42 | Image
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 | Nested Structures
51 |
52 |
53 |
54 |
MD Text
55 |
MD Text
56 |
57 |
58 |
59 |
60 |
61 | Gallery
62 | A gallery can be any Chunk in your element tree; or a TV attached to this resource.
63 | - Just specify a correct title pattern (of ANY structure);
64 | - Element Abbreviation (not case sensitive) + element ID = Ch23 or TV34
65 | - Use hyphen to optionally compound/suffix with other words;
66 |
67 | My Album - Ch23
68 | My Gallery Etc - Tv34
69 |
70 | - Then in a structure hover menu or main top nav, find Gallery (esc, g + 1)!
71 |
72 | Sample call for frontend display (using MIGX' getImageList)
73 |
74 | [[getImageList?
75 | &offset=`1`
76 | &where =`{"hidden:=":"0"}`
77 | &sort=`[{"sortby":"index","sortdir":"ASC","sortmode":"numeric"}]`
78 | &value=`[[$MyTuscanHoliday]]` // for raw data or chunk
79 | &tvname=`MyTuscanHoliday` // for TV when not using chunk
80 | &tpl=`MyTuscanHoliday_tpl`
81 | ]]
82 |
83 | *MyTuscanHoliday_tpl*
84 |
85 | `[[+folder]]` = url location of image - at this time you can use physical thumbnails: `[[+folder]]thumb200x100/`
86 | `[[+id]]` = image filename
87 | `[[+title]]` = image title extra info
88 | `[[+desc]]` = image description longer extra info
89 | `[[+tag]]` = image tag
90 | `[[+index]]` = image sort location
91 |
92 |
93 | img src="[[+folder]]thumb/[[+id]]" alt="[[+desc]]"
94 |
95 |
96 |
97 |
98 |
99 | Ace Source Code
100 |
101 |
// Ace Source Code
102 |
103 |
104 |
105 |
106 | Source Code Manager
107 |
108 |
// Source Code
109 |
110 |
111 |
112 |
113 | Partials
114 |
115 |
116 | Success Aside
117 |
118 |
119 |
120 |
121 | Warning Aside
122 |
123 |
124 |
125 |
126 | Notice Aside
127 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/core/components/structures/elements/chunks/st.tinymce_config.chunk.html:
--------------------------------------------------------------------------------
1 | /*
2 | Editor Legend. Simply give your element one of these purely functional classnames below
3 | .tb-tiny-fc = Full Content
4 | .tb-tiny-dc = Demo Code
5 | .tb-tiny-im = Image
6 | .tb-tiny-rc is reserved for Ace and CodeMirror
7 | if you create more, please stick with two letters after tb-tiny- ... for cleanup on webrender
8 |
9 | You may add classes for mgr styling purposes (without dot) or extra functionality
10 | Use prefix: tb-custom-
11 | addClasses:{
12 | toParent: "tb-custom-myStuff", //adds class(es) to the parent of your editor
13 | toSelf: "tb-custom-myEditor tb-custom-self" //adds class(es) to the editor itself
14 | }
15 | */
16 |
17 |
18 | // Default settings for full RText structure
19 | tinymce.init({
20 | selector: "[[+tinyBlocksMainWrapperId]] .tb-tiny-fc",
21 | inline: true,
22 | fixed_toolbar_container: "#tinyBlocksBubbleBar",
23 | mode: "exact",
24 | name: "RTE",
25 | noneditable_noneditable_class: "tb-mini",
26 | addClasses:{
27 | toParent: "tb-custom-fc-parent",
28 | toSelf: "tb-custom-fc"
29 | },
30 | save_onsavecallback: tinyBlocksSave,
31 | save_enablewhendirty: false,
32 | hidden_input: false,
33 | paste_data_images: true,
34 | media_live_embeds:true,
35 | image_caption: true,
36 | images_upload_base_path: '[[++assets_url]]components/structures/uploads/',
37 | images_upload_credentials: true,
38 | images_upload_handler: tinyBlocksRapidImage,
39 | tbRapidImageSettings:{
40 | uploadScriptUrl: "[[++assets_url]]components/structures/rapidimage/tinyBlocksRapidImage.php",
41 | uploadPath: "../uploads/", //relative to uploadScriptUrl
42 | uploadUrl: "[[++assets_url]]components/structures/uploads/" //web url to uploadPath
43 | },
44 | file_browser_callback: autoFileBrowser,
45 | relative_urls: false,
46 | //remove_script_host: false,
47 | document_base_url: MODx.config.site_url,
48 | browser_spellcheck: true,
49 | gecko_spellcheck: true,
50 | plugins: "structures bubbleBar modxMagicHoverLink twAceEditor twPreCodeManager table media imagetools contextmenu save paste image searchreplace hr noneditable template visualblocks",
51 | contextmenu: "code rapidImage unlink removeformat undo redo",
52 | toolbar1: "bold italic link image blockquote bullist numlist styleselect visualblocks | bubbleBarOptionsButton",
53 | toolbar2: "template twPreCodeManager | image media hr table",
54 | bubbleBarSettings: {
55 | magicInsert: {
56 | activate: 1,
57 | }
58 | },
59 | menubar: false,
60 | // content_style: ".mce-widget.mce-tooltip {display: none !important;}", // remove tooltips
61 | templates: tinyBlocksTemplateMenu,
62 | template_popup_width: 300,
63 | template_popup_height: 300,
64 | valid_elements: "*[*]", //user please edit
65 | formats: {
66 | insertparagraph: {
67 | block: "p"
68 | },
69 | alignleft: {
70 | selector: "p,h2,h3,",
71 | classes: "text-align-left"
72 | },
73 | aligncenter: {
74 | selector: "p,h1,h2,h3,",
75 | classes: "text-align-center"
76 | },
77 | alignright: {
78 | selector: "p,h2,h3,",
79 | classes: "text-align-right"
80 | }
81 | },
82 | style_formats_merge: true,
83 | skin_url: "[[+tinyBlocksSkinUrl]]"
84 | });
85 |
86 | // Demo Code structure settings
87 | tinymce.init({
88 | selector: "[[+tinyBlocksMainWrapperId]] .tb-tiny-dc",
89 | name: "Code",
90 | addClasses:{
91 | toParent: "tb-custom-dc-parent",
92 | toSelf: "tb-custom-dc"
93 | },
94 | inline: true,
95 | fixed_toolbar_container: "#tinyBlocksBubbleBar",
96 | save_onsavecallback: tinyBlocksSave,
97 | hidden_input: false,
98 | forced_root_block : "",
99 | force_br_newlines : false,
100 | force_p_newlines : false,
101 | valid_elements: "pre[*],code[*]",
102 | valid_children: "pre[code]",
103 | plugins: "structures twPreCodeManager save",
104 | twPreCodeManagerSettings: {
105 | managerPREcss: false,
106 | },
107 | toolbar: false,
108 | menubar: false,
109 | skin_url: "[[+tinyBlocksSkinUrl]]"
110 | });
111 |
112 | // Markdown editor settings
113 | tinymce.init({
114 | selector: "[[+tinyBlocksMainWrapperId]] .tb-tiny-md",
115 | name: "MD",
116 | addClasses:{
117 | toParent: "tb-custom-md-parent",
118 | toSelf: "tb-custom-md"
119 | },
120 | fixed_toolbar_container: "#tinyBlocksBubbleBar",
121 | inline: true,
122 | save_onsavecallback: tinyBlocksSave,
123 | file_browser_callback: autoFileBrowser,
124 | hidden_input: false,
125 | browser_spellcheck: true,
126 | gecko_spellcheck: true,
127 | toolbar1: "preview link boldMD italicMD imageMD blockquoteMD bubbleBarOptionsButton",
128 | toolbar2: "imageMD blockquoteMD code numlistMD bullistMD",
129 | menubar: false,
130 | //contextmenu: "preview link twPreCodeManager boldMD italicMD imageMD blockquoteMD codeMD numlistMD bullistMD",
131 | contextmenu: "twPreCodeManager blockquoteMD numlistMD bullistMD",
132 | forced_root_block : "p",
133 | force_br_newlines : false,
134 | force_p_newlines : true,
135 | valid_elements: "p,br[*]",
136 | valid_children: "p[br]",
137 | paste_as_text: true,
138 | plugins: "structures bubbleBar twPreCodeManager twExoticMarkdownEditor modxMagicHoverLink paste code contextmenu save searchreplace",
139 | twExoticMarkdownEditorSettings: {
140 | addClass: false,
141 | removeClasses: "tt-hidden tt-duplicate",
142 | skipClass: "tt-duplicate",
143 | addAttr: true
144 | },
145 | skin_url: "[[+tinyBlocksSkinUrl]]"
146 | });
147 |
148 | // Image structure settings
149 | tinymce.init({
150 | selector: "[[+tinyBlocksMainWrapperId]] .tb-tiny-im",
151 | name: "IMG",
152 | addClasses:{
153 | toParent: "tb-custom-im-parent",
154 | toSelf: "tb-custom-im"
155 | },
156 | inline: true,
157 | save_onsavecallback: tinyBlocksSave,
158 | hidden_input: false,
159 | plugins: "structures save image",
160 | forced_root_block : "",
161 | force_br_newlines : false,
162 | force_p_newlines : false,
163 | valid_elements: "-img[!class:img-responsive|!alt=image_alt|!src=about:blank]",
164 | // toolbar: false,
165 | menubar: false,
166 | file_browser_callback: autoFileBrowser,
167 | relative_urls: false,
168 | // remove_script_host: false,
169 | document_base_url: MODx.config.site_url,
170 | image_dimensions: false,
171 | paste_data_images: true,
172 | object_resizing : false,
173 | skin_url: "[[+tinyBlocksSkinUrl]]"
174 | });
--------------------------------------------------------------------------------
/core/components/structures/elements/snippets/structures.snippet.php:
--------------------------------------------------------------------------------
1 | newObject('modChunk')->process(null, $content);
5 | if($options == "markdown"){
6 | if (!class_exists('\Michelf\Markdown')) {
7 | require_once MODX_ASSETS_PATH . 'components/structures/markdown/Michelf/Markdown.inc.php';
8 | }
9 | $content = \Michelf\Markdown::defaultTransform($content);
10 | }
11 | elseif($options == "parsedown"){
12 | require_once MODX_ASSETS_PATH . 'components/structures/markdown/parsedown/Parsedown.php';
13 | $Parsedown = new Parsedown();
14 | $content = $Parsedown->text($content);
15 | }
16 | elseif($options == "parsedownExtra"){
17 | require_once MODX_ASSETS_PATH . 'components/structures/markdown/parsedown/Parsedown.php';
18 | require_once MODX_ASSETS_PATH . 'components/structures/markdown/parsedown/ParsedownExtra.php';
19 | $ParsedownExtra = new ParsedownExtra();
20 | $content = $ParsedownExtra->text($content);
21 | }
22 | else{ //default state (switchd from Parsedown - quite blows things up - silly goose!!!)
23 | $options = "markdownE";
24 | if (!class_exists('\Michelf\MarkdownExtra')) {
25 | require_once MODX_ASSETS_PATH . 'components/structures/markdown/Michelf/MarkdownExtra.inc.php';
26 | }
27 | $content = \Michelf\MarkdownExtra::defaultTransform($content);
28 | }
29 |
30 | $patterns = array( // highly rustic and silly, this method. Change to proper PHP HTMLdocument
31 | "/tb-nested-wrapper/",
32 | "/tb-nested-yes/",
33 | "/tb-nested-no/",
34 | "/tb-wrapper-tlb /",
35 | "/ tb-wrapper-tlb/",
36 | "/tb-wrapper-tlb/",
37 | "/tb-tiny-.. /",
38 | "/ tb-tiny-../",
39 | "/tb-tiny-../",
40 | "/tb-unwrap /",
41 | "/ tb-unwrap/"
42 | );
43 | $rep = array(
44 | "",
45 | "",
46 | "",
47 | "",
48 | "",
49 | "",
50 | "",
51 | "",
52 | "",
53 | "",
54 | ""
55 | );
56 | $content = str_replace('[*[', '[[', $content);
57 | $content = preg_replace($patterns, $rep, $content);
58 | return $content;
59 | }
--------------------------------------------------------------------------------
/core/components/structures/elements/templates/structures-lector.template.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
[[*pagetitle]][[*longtitle:notempty=`: [[*longtitle]]`]]
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
50 |
51 |
65 |
66 |
67 |
68 |
69 |
70 |
71 | [[*content:Structures]]
72 |
73 | Last modified: [[*editedon:strtotime:date=`%B %e, %Y %R %p`]] | Powered by Structures
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/core/components/structures/elements/templates/structures.template.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
Document
6 |
7 |
8 | [[*content:Structures]]
9 |
10 |
11 |
--------------------------------------------------------------------------------