Compare commits

...

10 Commits

Author SHA1 Message Date
b474b7986c 1.0.260 2024-01-22 01:26:13 +01:00
98542252cb fix(core): update 2024-01-22 01:26:13 +01:00
0d78deadf2 1.0.259 2024-01-22 01:11:29 +01:00
5108f47e56 fix(core): update 2024-01-22 01:11:28 +01:00
7d4e5f2ca7 1.0.258 2024-01-22 00:59:26 +01:00
c0ad0f4570 fix(core): update 2024-01-22 00:59:25 +01:00
d56eb602a9 1.0.257 2024-01-21 22:37:39 +01:00
f1c791eb12 fix(core): update 2024-01-21 22:37:39 +01:00
e872188be7 1.0.256 2024-01-21 17:14:16 +01:00
2d712e78b0 fix(core): update 2024-01-21 17:14:15 +01:00
5 changed files with 112 additions and 38 deletions

View File

@@ -1,6 +1,6 @@
{ {
"name": "@design.estate/dees-catalog", "name": "@design.estate/dees-catalog",
"version": "1.0.255", "version": "1.0.260",
"private": false, "private": false,
"description": "website for lossless.com", "description": "website for lossless.com",
"main": "dist_ts_web/index.js", "main": "dist_ts_web/index.js",

View File

@@ -3,6 +3,6 @@
*/ */
export const commitinfo = { export const commitinfo = {
name: '@design.estate/dees-catalog', name: '@design.estate/dees-catalog',
version: '1.0.255', version: '1.0.260',
description: 'website for lossless.com' description: 'website for lossless.com'
} }

View File

@@ -52,6 +52,7 @@ import {
faFileInvoiceDollar as faFileInvoiceDollarSolid, faFileInvoiceDollar as faFileInvoiceDollarSolid,
faGear as faGearSolid, faGear as faGearSolid,
faGrip as faGripSolid, faGrip as faGripSolid,
faMagnifyingGlass as faMagnifyingGlassSolid,
faMessage as faMessageSolid, faMessage as faMessageSolid,
faMoneyCheckDollar as faMoneyCheckDollarSolid, faMoneyCheckDollar as faMoneyCheckDollarSolid,
faMugHot as faMugHotSolid, faMugHot as faMugHotSolid,
@@ -97,6 +98,7 @@ export const faIcons = {
fileInvoiceDoller: faFileInvoiceDollarSolid, fileInvoiceDoller: faFileInvoiceDollarSolid,
gear: faGearSolid, gear: faGearSolid,
grip: faGripSolid, grip: faGripSolid,
magnifyingGlass: faMagnifyingGlassSolid,
message: faMessageRegular, message: faMessageRegular,
messageSolid: faMessageSolid, messageSolid: faMessageSolid,
moneyCheckDollar: faMoneyCheckDollarSolid, moneyCheckDollar: faMoneyCheckDollarSolid,

View File

@@ -27,30 +27,54 @@ export class DeesSimpleAppDash extends DeesElement {
@property() @property()
public name = 'Dees Simple Login'; public name = 'Dees Simple Login';
@property()
public views: Array<{ name: string; icon: string; viewFunction: () => Promise<TemplateResult> }> = [];
public static styles = [ public static styles = [
cssManager.defaultStyles, cssManager.defaultStyles,
css` css`
:host { :host {
color: ${cssManager.bdTheme('#333', '#fff')}; color: ${cssManager.bdTheme('#333', '#ccc')};
user-select: none; user-select: none;
} }
.appbar { .appbar {
position: absolute; position: fixed;
top: 0; top: 0;
height: 40px; height: 40px;
width: 100%; width: 100%;
background: ${cssManager.bdTheme('#eeeeeb', '#000')}; background: ${cssManager.bdTheme('#eeeeeb', '#222')};
border-bottom: 1px solid ${cssManager.bdTheme('#ccc', '#333')}; border-bottom: 1px solid ${cssManager.bdTheme('#ccc', '#ffffff10')};
font-size: 14px; font-size: 14px;
line-height: 40px; line-height: 40px;
font-family: 'Roboto', 'Inter', sans-serif; font-family: 'Roboto', 'Inter', sans-serif;
padding: 0px 16px; padding: 0px 16px;
z-index: 2;
box-shadow: 0px 0px 4px 0px rgba(0, 0, 0, 0.2);
display: grid;
grid-template-columns: min-content 1fr auto;
} }
.appName {
white-space: nowrap;
}
.appActions {
display: flex;
}
.appActions .action {}
.appActions .action:hover {
color: ${cssManager.bdTheme('#000', '#fff')};
}
.appcontent { .appcontent {
position: absolute; z-index: 1;
position: fixed;
top: 40px; top: 40px;
bottom: 0; height: calc(100vh - 40px);
bottom: 0px;
width: 100%; width: 100%;
overflow: auto;
background: ${cssManager.bdTheme('#eeeeeb', '#000')}; background: ${cssManager.bdTheme('#eeeeeb', '#000')};
} }
`, `,
@@ -59,7 +83,13 @@ export class DeesSimpleAppDash extends DeesElement {
public render(): TemplateResult { public render(): TemplateResult {
return html` return html`
<div class="appbar"> <div class="appbar">
configvault v1.2.3 <div class="appName">${this.name}</div>
<div class="viewTabs"></div>
<div class="appActions">
<div class="action">
Logout
</div>
</div>
</div> </div>
<div class="appcontent"> <div class="appcontent">
<slot></slot> <slot></slot>

View File

@@ -117,12 +117,21 @@ export class DeesTable<T> extends DeesElement {
public changeSubject = new domtools.plugins.smartrx.rxjs.Subject<DeesTable<T>>(); public changeSubject = new domtools.plugins.smartrx.rxjs.Subject<DeesTable<T>>();
// end dees-form compatibility ----------------------------------------- // end dees-form compatibility -----------------------------------------
/**
* What does a row of data represent?
*/
@property({ @property({
type: String, type: String,
reflect: true, reflect: true,
}) })
public dataName: string; public dataName: string;
@property({
type: Boolean,
})
searchable: boolean = true;
@property({ @property({
type: Array, type: Array,
}) })
@@ -203,11 +212,16 @@ export class DeesTable<T> extends DeesElement {
} }
.headerActions { .headerActions {
user-select: none;
display: flex;
flex-direction: row;
margin-left: auto; margin-left: auto;
} }
.headerAction { .headerAction {
display: flex; display: flex;
flex-direction: row;
color: ${cssManager.bdTheme('#333', '#ccc')}; color: ${cssManager.bdTheme('#333', '#ccc')};
margin-left: 16px;
} }
.headerAction:hover { .headerAction:hover {
@@ -223,9 +237,17 @@ export class DeesTable<T> extends DeesElement {
display: grid; display: grid;
grid-gap: 16px; grid-gap: 16px;
grid-template-columns: 1fr 200px; grid-template-columns: 1fr 200px;
margin: 0px -16px; margin-top: 16px;
padding: 0px 16px; padding: 0px 16px;
border-bottom: 1px solid ${cssManager.bdTheme('#fff', '#ffffff20')}; border-top: 1px solid ${cssManager.bdTheme('#fff', '#ffffff20')};
border-radius: 8px;
}
.searchGrid.hidden {
height: 0px;
opacity: 0;
overflow: hidden;
margin-top: 0px;
} }
table, table,
@@ -315,10 +337,12 @@ export class DeesTable<T> extends DeesElement {
font-weight: inherit; font-weight: inherit;
padding: 0px 6px; padding: 0px 6px;
} }
.actionContainer { .actionsContainer {
display: flex;
flex-direction: row;
height: 24px; height: 24px;
display: inline-block;
transform: translateY(-4px); transform: translateY(-4px);
margin-left: -6px;
} }
.action { .action {
position: relative; position: relative;
@@ -329,11 +353,6 @@ export class DeesTable<T> extends DeesElement {
border-radius: 8px; border-radius: 8px;
} }
.actionContainer:first-child {
margin-left: -6px;
width: min-content;
}
.action:hover { .action:hover {
background: ${cssManager.bdTheme(colors.bright.blue, colors.dark.blue)}; background: ${cssManager.bdTheme(colors.bright.blue, colors.dark.blue)};
} }
@@ -422,7 +441,7 @@ export class DeesTable<T> extends DeesElement {
</div> </div>
</div> </div>
<div class="headingSeparation"></div> <div class="headingSeparation"></div>
<div class="searchGrid"> <div class="searchGrid hidden">
<dees-input-text <dees-input-text
.label=${'lucene syntax search'} .label=${'lucene syntax search'}
.description=${` .description=${`
@@ -574,24 +593,28 @@ export class DeesTable<T> extends DeesElement {
return html` return html`
<td> <td>
<div class="innerCellContainer"> <div class="innerCellContainer">
${this.getActionsForType('inRow').map( <div class="actionsContainer">
(actionArg) => html`<div class="actionContainer"> ${this.getActionsForType('inRow').map(
<div (actionArg) => html`
class="action" <div
@click=${() => class="action"
actionArg.actionFunc({ @click=${() =>
item: itemArg, actionArg.actionFunc({
table: this, item: itemArg,
})} table: this,
> })}
${actionArg.iconName >
? html` ${actionArg.iconName
<dees-icon .iconFA=${actionArg.iconName}></dees-icon> ? html`
` <dees-icon
: actionArg.name} .iconFA=${actionArg.iconName}
</div> ></dees-icon>
</div>` `
)} : actionArg.name}
</div>
`
)}
</div>
</div> </div>
</td> </td>
`; `;
@@ -640,11 +663,30 @@ export class DeesTable<T> extends DeesElement {
`; `;
} }
public async firstUpdated() {} public async firstUpdated() {
}
public async updated(changedProperties: Map<string | number | symbol, unknown>): Promise<void> { public async updated(changedProperties: Map<string | number | symbol, unknown>): Promise<void> {
super.updated(changedProperties); super.updated(changedProperties);
this.determineColumnWidths(); this.determineColumnWidths();
if (this.searchable) {
const existing = this.dataActions.find((actionArg) => actionArg.type.includes('header') && actionArg.name === 'Search');
if (!existing) {
this.dataActions.unshift({
name: 'Search',
iconName: 'magnifyingGlass',
type: ['header'],
actionFunc: async () => {
console.log('open search');
const searchGrid = this.shadowRoot.querySelector('.searchGrid');
searchGrid.classList.toggle('hidden');
}
});
console.log(this.dataActions);
this.requestUpdate();
};
}
} }
public async determineColumnWidths() { public async determineColumnWidths() {