add split panel to sidebar nav
This commit is contained in:
@@ -263,7 +263,7 @@ export class UmbSplitPanelElement extends LitElement {
|
||||
--umb-split-panel-divider-color: transparent;
|
||||
}
|
||||
slot {
|
||||
overflow: hidden;
|
||||
overflow: visible;
|
||||
display: block;
|
||||
}
|
||||
#main {
|
||||
|
||||
@@ -77,24 +77,26 @@ export class UmbSectionDefaultElement extends UmbLitElement implements UmbSectio
|
||||
|
||||
render() {
|
||||
return html`
|
||||
${this._sidebarApps && this._sidebarApps.length > 0
|
||||
? html`
|
||||
<!-- TODO: these extensions should be combined into one type: sectionSidebarApp with a "subtype" -->
|
||||
<umb-section-sidebar>
|
||||
${repeat(
|
||||
this._sidebarApps,
|
||||
(app) => app.alias,
|
||||
(app) => app.component,
|
||||
)}
|
||||
</umb-section-sidebar>
|
||||
`
|
||||
: nothing}
|
||||
<umb-section-main>
|
||||
${this._routes && this._routes.length > 0
|
||||
? html`<umb-router-slot id="router-slot" .routes=${this._routes}></umb-router-slot>`
|
||||
<umb-split-panel lock="start" snap="300px">
|
||||
${this._sidebarApps && this._sidebarApps.length > 0
|
||||
? html`
|
||||
<!-- TODO: these extensions should be combined into one type: sectionSidebarApp with a "subtype" -->
|
||||
<umb-section-sidebar slot="start">
|
||||
${repeat(
|
||||
this._sidebarApps,
|
||||
(app) => app.alias,
|
||||
(app) => app.component,
|
||||
)}
|
||||
</umb-section-sidebar>
|
||||
`
|
||||
: nothing}
|
||||
<slot></slot>
|
||||
</umb-section-main>
|
||||
<umb-section-main slot="end">
|
||||
${this._routes && this._routes.length > 0
|
||||
? html`<umb-router-slot id="router-slot" .routes=${this._routes}></umb-router-slot>`
|
||||
: nothing}
|
||||
<slot></slot>
|
||||
</umb-section-main>
|
||||
</umb-split-panel>
|
||||
`;
|
||||
}
|
||||
|
||||
@@ -106,6 +108,18 @@ export class UmbSectionDefaultElement extends UmbLitElement implements UmbSectio
|
||||
height: 100%;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
umb-split-panel {
|
||||
--umb-split-panel-initial-position: 200px;
|
||||
--umb-split-panel-start-min-width: 200px;
|
||||
--umb-split-panel-start-max-width: 400px;
|
||||
--umb-split-panel-end-min-width: 600px;
|
||||
}
|
||||
@media only screen and (min-width: 800px) {
|
||||
umb-split-panel {
|
||||
--umb-split-panel-initial-position: 300px;
|
||||
}
|
||||
}
|
||||
`,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -136,10 +136,10 @@ export class UmbSectionSidebarContextMenuElement extends UmbLitElement {
|
||||
}
|
||||
#action-modal {
|
||||
position: absolute;
|
||||
left: var(--umb-section-sidebar-width);
|
||||
height: 100%;
|
||||
z-index: 1;
|
||||
top: 0;
|
||||
right: calc(var(--umb-section-sidebar-width) * -1);
|
||||
width: var(--umb-section-sidebar-width);
|
||||
border: none;
|
||||
border-left: 1px solid var(--uui-color-border);
|
||||
|
||||
@@ -29,6 +29,7 @@ export class UmbSectionSidebarElement extends UmbLitElement {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
z-index: 10;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#scroll-container {
|
||||
|
||||
Reference in New Issue
Block a user