user groups

This commit is contained in:
Jesper Møller Jensen
2023-06-06 16:06:35 +12:00
parent d3015fb84c
commit d4bd62386a
3 changed files with 13 additions and 34 deletions

View File

@@ -1,6 +1,6 @@
import { UmbUserGroupCollectionContext } from './user-group-collection.context.js';
import { UUITextStyles , UUIInputEvent } from '@umbraco-cms/backoffice/external/uui';
import { css, html , customElement } from '@umbraco-cms/backoffice/external/lit';
import { UUITextStyles, UUIInputEvent } from '@umbraco-cms/backoffice/external/uui';
import { css, html, customElement } from '@umbraco-cms/backoffice/external/lit';
import { UMB_COLLECTION_CONTEXT_TOKEN } from '@umbraco-cms/backoffice/collection';
import { UmbLitElement } from '@umbraco-cms/internal/lit-element';
@@ -26,31 +26,17 @@ export class UmbUserGroupCollectionHeaderElement extends UmbLitElement {
render() {
return html`
<div id="sticky-top">
<div id="collection-top-bar">
<uui-button @click=${this.#onCreate} label="Create group" look="outline"></uui-button>
<uui-input @input=${this.#onSearch} label="search" id="input-search"></uui-input>
</div>
</div>
<uui-button @click=${this.#onCreate} label="Create group" look="outline"></uui-button>
<uui-input @input=${this.#onSearch} label="search" id="input-search"></uui-input>
`;
}
static styles = [
UUITextStyles,
css`
#sticky-top {
position: sticky;
top: 0px;
z-index: 1;
box-shadow: 0 1px 3px rgba(0, 0, 0, 0), 0 1px 2px rgba(0, 0, 0, 0);
transition: 250ms box-shadow ease-in-out;
}
#sticky-top.header-shadow {
box-shadow: var(--uui-shadow-depth-2);
}
#collection-top-bar {
padding: var(--uui-size-space-4) var(--uui-size-layout-1);
:host {
height: 100%;
width: 100%;
padding: 0 var(--uui-size-layout-1);
background-color: var(--uui-color-background);
display: flex;
justify-content: space-between;

View File

@@ -1,6 +1,6 @@
import { UmbUserGroupCollectionContext } from './user-group-collection.context.js';
import { UUITextStyles } from '@umbraco-cms/backoffice/external/uui';
import { css, html , customElement, state } from '@umbraco-cms/backoffice/external/lit';
import { css, html, customElement, state } from '@umbraco-cms/backoffice/external/lit';
import { UmbLitElement } from '@umbraco-cms/internal/lit-element';
import { UMB_COLLECTION_CONTEXT_TOKEN } from '@umbraco-cms/backoffice/collection';
import { UserGroupResponseModel } from '@umbraco-cms/backoffice/backend-api';
@@ -127,13 +127,6 @@ export class UmbUserGroupCollectionViewElement extends UmbLitElement {
static styles = [
UUITextStyles,
css`
:host {
height: 100%;
display: flex;
flex-direction: column;
margin: var(--uui-size-layout-1);
}
umb-table {
padding: 0;
}

View File

@@ -18,11 +18,11 @@ export class UmbUserCollectionElement extends UmbLitElement {
render() {
return html`
<uui-scroll-container>
<umb-user-group-collection-header></umb-user-group-collection-header>
<umb-body-layout header-clear header-shadow>
<umb-user-group-collection-header slot="header"></umb-user-group-collection-header>
<umb-user-group-collection-view></umb-user-group-collection-view>
</uui-scroll-container>
<umb-collection-selection-actions></umb-collection-selection-actions>
<umb-collection-selection-actions slot="footer"></umb-collection-selection-actions>
</umb-body-layout>
`;
}