Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xavier Thompson
erp5
Commits
a89c7e9e
Commit
a89c7e9e
authored
Nov 09, 2022
by
Rafael Monnerat
Committed by
Jérome Perrin
Dec 20, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_monaco_editor: Add Precache Manifest script
Probably there are missing files but it is a start.
parent
8424dbe2
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
241 additions
and
0 deletions
+241
-0
bt5/erp5_monaco_editor/SkinTemplateItem/portal_skins/erp5_monaco_editor/WebSection_getMonacoEditorPrecacheManifestList.py
..._editor/WebSection_getMonacoEditorPrecacheManifestList.py
+12
-0
bt5/erp5_monaco_editor/SkinTemplateItem/portal_skins/erp5_monaco_editor/WebSection_getMonacoEditorPrecacheManifestList.xml
...editor/WebSection_getMonacoEditorPrecacheManifestList.xml
+62
-0
bt5/erp5_monaco_editor_ui_test/PathTemplateItem/portal_tests/monaco_editor_zuite/testTextEditorCacheManifest.xml
...tests/monaco_editor_zuite/testTextEditorCacheManifest.xml
+58
-0
bt5/erp5_monaco_editor_ui_test/PathTemplateItem/portal_tests/monaco_editor_zuite/testTextEditorCacheManifest.zpt
...tests/monaco_editor_zuite/testTextEditorCacheManifest.zpt
+109
-0
No files found.
bt5/erp5_monaco_editor/SkinTemplateItem/portal_skins/erp5_monaco_editor/WebSection_getMonacoEditorPrecacheManifestList.py
0 → 100644
View file @
a89c7e9e
url_list
=
[
"monaco-editor.gadget.html"
,
"monaco-editor.gadget.js"
,
"jslint.js"
,
"monaco-editor/prettier@2.0.5/parser-babel.js"
,
"monaco-editor/prettier@2.0.5/standalone.js"
,
"monaco-editor/app.bundle.min.js"
,
"monaco-editor/editor.worker.bundle.min.js"
,
"monaco-editor/3703.bundle.min.js"
]
return
url_list
bt5/erp5_monaco_editor/SkinTemplateItem/portal_skins/erp5_monaco_editor/WebSection_getMonacoEditorPrecacheManifestList.xml
0 → 100644
View file @
a89c7e9e
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"PythonScript"
module=
"Products.PythonScripts.PythonScript"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
Script_magic
</string>
</key>
<value>
<int>
3
</int>
</value>
</item>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
name_container
</string>
</key>
<value>
<string>
container
</string>
</value>
</item>
<item>
<key>
<string>
name_context
</string>
</key>
<value>
<string>
context
</string>
</value>
</item>
<item>
<key>
<string>
name_m_self
</string>
</key>
<value>
<string>
script
</string>
</value>
</item>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
REQUEST=None
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
WebSection_getMonacoEditorPrecacheManifestList
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_monaco_editor_ui_test/PathTemplateItem/portal_tests/monaco_editor_zuite/testTextEditorCacheManifest.xml
0 → 100644
View file @
a89c7e9e
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ZopePageTemplate"
module=
"Products.PageTemplates.ZopePageTemplate"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
expand
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
testTextEditorCacheManifest
</string>
</value>
</item>
<item>
<key>
<string>
output_encoding
</string>
</key>
<value>
<string>
utf-8
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<unicode>
Text Editor Cache Manifest
</unicode>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_monaco_editor_ui_test/PathTemplateItem/portal_tests/monaco_editor_zuite/testTextEditorCacheManifest.zpt
0 → 100644
View file @
a89c7e9e
<html
xmlns:tal=
"http://xml.zope.org/namespaces/tal"
xmlns:metal=
"http://xml.zope.org/namespaces/metal"
>
<head>
<meta
http-equiv=
"Content-Type"
content=
"text/html; charset=UTF-8"
>
<title
tal:content=
"template/title_and_id"
></title>
</head>
<body>
<table
cellpadding=
"1"
cellspacing=
"1"
border=
"1"
>
<thead>
<tr>
<td
rowspan=
"1"
colspan=
"3"
tal:content=
"template/title_and_id"
></td>
</tr>
</thead>
<tbody>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplate/macros/init"
/>
<tr>
<td>
open
</td>
<td>
${base_url}/foo_module/ListBoxZuite_reset
</td>
<td></td>
</tr>
<tr>
<td>
assertTextPresent
</td>
<td>
Reset Successfully.
</td>
<td></td>
</tr>
<tr>
<td
colspan=
"3"
><b>
Set prefered text editor
</b></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/portal_preferences/erp5_ui_test_preference/Preference_viewHtmlStyle
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//input[@name="field_my_preferred_text_editor" and @value="monaco"]
</td>
<td></td>
</tr>
<tr>
<td>
clickAndWait
</td>
<td>
//button[@name='Base_edit:method']
</td>
<td></td>
</tr>
<tr>
<td
colspan=
"3"
><b>
Make a new web site using our cache manifest
</b></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/renderjs_runner/?ignore_layout:int=1
&
editable_mode:int=1
</td>
<td></td>
</tr>
<tr>
<td>
clickAndWait
</td>
<td>
name=Base_createCloneDocument:method
</td>
<td></td>
</tr>
<tr>
<td>
assertPortalStatusMessage
</td>
<td>
Created Clone Web Site.
</td>
<td></td>
</tr>
<tr>
<td>
storeValue
</td>
<td>
name=field_my_id
</td>
<td>
new_web_site_id
</td>
</tr>
<tr>
<td>
clickAndWait
</td>
<td>
link=Layout Configuration
</td>
<td></td>
</tr>
<tr>
<td>
type
</td>
<td>
field_my_configuration_precache_manifest_script_list
</td>
<td><br/>
WebSection_getMonacoEditorPrecacheManifestList
</td>
</tr>
<tr>
<td>
clickAndWait
</td>
<td>
name=Base_edit:method
</td>
<td></td>
</tr>
<tr>
<td>
assertPortalStatusMessage
</td>
<td>
Data updated.
</td>
<td></td>
</tr>
<tr>
<td
colspan=
"3"
><b>
Switch to renderjs UI and check the manifest is loaded
</b></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/${new_web_site_id}/#/web_page_module?editable=true
</td>
<td></td>
</tr>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded"
/>
<tr>
<td>
waitForCondition
</td>
<td>
selenium.browserbot.currentWindow.navigator.serviceWorker.controller !== null
</td>
<td>
180000
</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment