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
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Vincent Bechu
erp5
Commits
ca932707
Commit
ca932707
authored
Dec 13, 2017
by
Vincent Bechu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Add possibility to hide panel in desktop view
parent
2c22f4ff
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
179 additions
and
12 deletions
+179
-12
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
...mplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
+18
-0
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
...plateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
+3
-3
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.css
...emplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.css
+80
-3
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.xml
...emplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.xml
+3
-3
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/erp5css.less.txt
...teItem/portal_skins/erp5_web_renderjs_ui/erp5css.less.txt
+75
-3
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
View file @
ca932707
...
...
@@ -169,6 +169,21 @@
return
displayErrorContent
(
gadget
,
error
);
}
function
hideDesktopPanel
(
gadget
,
hide
)
{
gadget
.
props
.
hide_panel
=
hide
;
if
(
hide
)
{
if
(
!
gadget
.
element
.
classList
.
contains
(
'
desktop-panel-hidden
'
))
{
gadget
.
element
.
classList
.
toggle
(
'
desktop-panel-hidden
'
);
}
return
route
(
gadget
,
"
panel
"
,
"
close
"
);
}
else
{
if
(
gadget
.
element
.
classList
.
contains
(
'
desktop-panel-hidden
'
))
{
gadget
.
element
.
classList
.
remove
(
'
desktop-panel-hidden
'
);
}
return
route
(
gadget
,
"
panel
"
,
"
open
"
);
}
}
//////////////////////////////////////////
// Page rendering
//////////////////////////////////////////
...
...
@@ -426,6 +441,9 @@
gadget
.
props
.
panel_argument_list
=
param_list
[
0
];
})
.
allowPublicAcquisition
(
'
hidePanel
'
,
function
(
param_list
)
{
return
hideDesktopPanel
(
this
,
param_list
[
0
]);
})
.
allowPublicAcquisition
(
'
triggerPanel
'
,
function
()
{
return
route
(
this
,
"
panel
"
,
"
toggle
"
);
})
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
View file @
ca932707
...
...
@@ -216,7 +216,7 @@
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
<value>
<string>
vincent
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
...
...
@@ -230,7 +230,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
96
3.29105.23200.50073
</string>
</value>
<value>
<string>
96
4.7125.64671.33655
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>
151
1971674.78
</float>
<float>
151
3180213.26
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.css
View file @
ca932707
...
...
@@ -436,6 +436,8 @@ div[data-gadget-scope='panel'] {
left
:
0
;
display
:
block
;
z-index
:
2000
;
transition
:
transform
200ms
ease-out
;
transform
:
translate3d
(
0
,
0
,
0
);
}
@media
not
screen
and
(
min-width
:
45em
),
only
screen
and
(
min-width
:
45em
)
and
(
max-width
:
85em
)
{
div
[
data-gadget-scope
=
'panel'
]
{
...
...
@@ -445,8 +447,6 @@ div[data-gadget-scope='panel'] {
@media
not
screen
and
(
min-width
:
45em
),
only
screen
and
(
min-width
:
45em
)
and
(
max-width
:
85em
)
{
div
[
data-gadget-scope
=
'panel'
]
{
left
:
-186pt
;
transition
:
transform
200ms
ease-out
;
transform
:
translate3d
(
0
,
0
,
0
);
}
div
[
data-gadget-scope
=
'panel'
]
.visible
{
transform
:
translate3d
(
186pt
,
0
,
0
);
...
...
@@ -686,7 +686,8 @@ div[data-gadget-scope='header'] .ui-header {
}
@media
not
screen
and
(
max-width
:
85em
)
{
div
[
data-gadget-scope
=
'header'
]
.ui-header
{
margin-left
:
180pt
;
transition
:
transform
200ms
ease-out
;
transform
:
translate3d
(
180pt
,
0
,
0
);
}
}
div
[
data-gadget-scope
=
'header'
]
.ui-header
button
,
...
...
@@ -873,6 +874,7 @@ div[data-gadget-scope='header'] .ui-header ul {
div
[
data-gadget-scope
=
'header'
]
.ui-header
ul
li
a
{
padding-top
:
3pt
;
padding-bottom
:
3pt
;
line-height
:
inherit
;
white-space
:
nowrap
;
overflow
:
hidden
;
}
...
...
@@ -1497,6 +1499,81 @@ div[data-gadget-scope='notification'] button.error {
}
}
/**********************************************
* Desktop Panel Hidden
**********************************************/
@media
not
screen
and
(
max-width
:
85em
)
{
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
{
margin-left
:
0
;
transform
:
translate3d
(
0
,
0
,
0
);
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
.ui-controlgroup-controls
button
,
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
.ui-controlgroup-controls
a
{
background-color
:
#085078
;
width
:
8em
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
.ui-controlgroup-controls
button
[
name
=
"panel"
],
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
.ui-controlgroup-controls
a
[
name
=
"panel"
]
{
display
:
block
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
>
.ui-btn-right
button
,
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
>
.ui-btn-right
a
{
border-left
:
1px
solid
rgba
(
255
,
255
,
255
,
0.55
);
padding-left
:
0
;
padding-right
:
0
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
h1
{
flex
:
1
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
h1
>
span
{
padding-left
:
16pt
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
h1
>
span
::before
{
margin-right
:
14pt
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
h1
a
::before
,
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
h1
form
button
::before
{
text-align
:
center
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
.ui-subheader
{
text-align
:
center
;
flex
:
1
100%
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
ul
>
li
{
flex
:
1
;
border-left
:
1px
solid
rgba
(
0
,
0
,
0
,
0.55
);
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
ul
>
li
:first-child
{
border-left
:
none
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
ul
>
li
a
{
display
:
block
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
ul
>
li
a
{
padding-top
:
3pt
;
padding-bottom
:
3pt
;
line-height
:
inherit
;
white-space
:
nowrap
;
overflow
:
hidden
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
"header"
]
.ui-header
ul
>
li
a
::before
{
font-size
:
1.2em
;
display
:
block
;
}
.desktop-panel-hidden
.gadget-content
{
margin-left
:
0
;
padding-top
:
7em
;
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
'panel'
]
{
transform
:
translate3d
(
-186pt
,
0
,
0
);
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
'panel'
]
.visible
{
transform
:
translate3d
(
0
,
0
,
0
);
}
.desktop-panel-hidden
div
[
data-gadget-scope
=
'panel'
]
div
[
data-role
=
"header"
]
button
[
data-i18n
=
"Close"
]
{
display
:
block
;
}
}
/**********************************************
* Class
**********************************************/
.content-iframe-maximize
{
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_nojqm_css.xml
View file @
ca932707
...
...
@@ -228,7 +228,7 @@
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
<value>
<string>
vincent
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
...
...
@@ -242,7 +242,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
96
3.49524.2871.19182
</string>
</value>
<value>
<string>
96
4.7132.37648.59101
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -260,7 +260,7 @@
</tuple>
<state>
<tuple>
<float>
151
2052879.86
</float>
<float>
151
3180665.25
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/erp5css.less.txt
View file @
ca932707
...
...
@@ -545,10 +545,11 @@ div[data-gadget-scope='panel'] {
display: block;
z-index: 2000;
transition: transform 200ms ease-out;
transform: translate3d(0, 0, 0);
@media @smartphone, @tablet {
left: -@panelwidth - @margin-size;
transition: transform 200ms ease-out;
transform: translate3d(0, 0, 0);
&.visible {
transform: translate3d(@panelwidth + @margin-size, 0, 0);
}
...
...
@@ -816,6 +817,7 @@ div[data-gadget-scope='editor_panel'] {
.renderTabletSubLink() {
padding-top: @half-margin-size;
padding-bottom: @half-margin-size;
line-height: inherit;
white-space: nowrap;
overflow: hidden;
&::before {
...
...
@@ -855,7 +857,8 @@ div[data-gadget-scope='header'] .ui-header {
width: 100%;
@media @desktop {
margin-left: @panelwidth;
transition: transform 200ms ease-out;
transform: translate3d(@panelwidth, 0, 0);
}
color: @white;
...
...
@@ -1719,7 +1722,76 @@ div[data-gadget-scope='notification'] {
from {opacity:0;}
to {opacity:1;}
}
/**********************************************
* Desktop Panel Hidden
**********************************************/
@media @desktop {
.desktop-panel-hidden {
div[data-gadget-scope="header"] .ui-header {
margin-left: 0;
transform: translate3d(0, 0, 0);
.ui-controlgroup-controls {
button, a {
background-color: @colorheaderbackground;
width: 8em;
&[name="panel"] {
display: block;
}
}
}
& > .ui-btn-right {
button, a {
border-left: 1px solid rgba(255, 255, 255, 0.55);
padding-left: 0;
padding-right: 0;
}
}
h1 {
flex: 1;
& > span {
.renderTabletNotALinkTitle();
}
a, form button {
&::before {
text-align: center;
}
}
}
.ui-subheader {
text-align: center;
flex: 1 100%;
}
ul > li {
.renderTabletSubListElement();
a {
.renderTabletSubLink();
}
}
}
.gadget-content {
margin-left: 0;
padding-top: 7em;
}
div[data-gadget-scope='panel'] {
transform: translate3d(-@panelwidth - @margin-size, 0, 0);
&.visible {
transform: translate3d(0, 0, 0);
}
div[data-role="header"] {
button[data-i18n="Close"] {
display: block;
}
}
}
}
}
/**********************************************
* Class
**********************************************/
...
...
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