@leavittsoftware/web 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/leavitt/api-service/HttpError.d.ts +10 -0
- package/leavitt/api-service/HttpError.js +2 -0
- package/leavitt/api-service/HttpError.js.map +1 -0
- package/leavitt/api-service/api-service.d.ts +27 -0
- package/leavitt/api-service/api-service.js +332 -0
- package/leavitt/api-service/api-service.js.map +1 -0
- package/leavitt/api-service/api2-service.d.ts +338 -0
- package/leavitt/api-service/api2-service.js +17 -0
- package/leavitt/api-service/api2-service.js.map +1 -0
- package/leavitt/api-service/authenticated-token-provider.d.ts +5 -0
- package/leavitt/api-service/authenticated-token-provider.js +7 -0
- package/leavitt/api-service/authenticated-token-provider.js.map +1 -0
- package/leavitt/api-service/bearer-token-provider.d.ts +4 -0
- package/leavitt/api-service/bearer-token-provider.js +2 -0
- package/leavitt/api-service/bearer-token-provider.js.map +1 -0
- package/leavitt/api-service/mapi-service.d.ts +338 -0
- package/leavitt/api-service/mapi-service.js +17 -0
- package/leavitt/api-service/mapi-service.js.map +1 -0
- package/leavitt/api-service/no-authentication-token-provider.d.ts +5 -0
- package/leavitt/api-service/no-authentication-token-provider.js +6 -0
- package/leavitt/api-service/no-authentication-token-provider.js.map +1 -0
- package/leavitt/api-service/odata-dto.d.ts +6 -0
- package/leavitt/api-service/odata-dto.js +7 -0
- package/leavitt/api-service/odata-dto.js.map +1 -0
- package/leavitt/api-service/odata-model-info.d.ts +5 -0
- package/leavitt/api-service/odata-model-info.js +7 -0
- package/leavitt/api-service/odata-model-info.js.map +1 -0
- package/leavitt/api-service/odata-response.d.ts +15 -0
- package/leavitt/api-service/odata-response.js +50 -0
- package/leavitt/api-service/odata-response.js.map +1 -0
- package/leavitt/api-service/status-codes.d.ts +2 -0
- package/leavitt/api-service/status-codes.js +44 -0
- package/leavitt/api-service/status-codes.js.map +1 -0
- package/leavitt/company-select/company-select.d.ts +50 -0
- package/leavitt/company-select/company-select.js +157 -0
- package/leavitt/company-select/company-select.js.map +1 -0
- package/leavitt/person-company-select/person-company-select.d.ts +41 -0
- package/leavitt/person-company-select/person-company-select.js +180 -0
- package/leavitt/person-company-select/person-company-select.js.map +1 -0
- package/leavitt/person-group-select/people-group-icons.d.ts +5 -0
- package/leavitt/person-group-select/people-group-icons.js +66 -0
- package/leavitt/person-group-select/people-group-icons.js.map +1 -0
- package/leavitt/person-group-select/person-group-select.d.ts +41 -0
- package/leavitt/person-group-select/person-group-select.js +186 -0
- package/leavitt/person-group-select/person-group-select.js.map +1 -0
- package/leavitt/person-select/person-select.d.ts +33 -0
- package/leavitt/person-select/person-select.js +128 -0
- package/leavitt/person-select/person-select.js.map +1 -0
- package/leavitt/profile-picture/profile-picture-menu.d.ts +44 -0
- package/leavitt/profile-picture/profile-picture-menu.js +197 -0
- package/leavitt/profile-picture/profile-picture-menu.js.map +1 -0
- package/leavitt/profile-picture/profile-picture.d.ts +39 -0
- package/leavitt/profile-picture/profile-picture.js +151 -0
- package/leavitt/profile-picture/profile-picture.js.map +1 -0
- package/leavitt/user-feedback/user-feedback.d.ts +357 -0
- package/leavitt/user-feedback/user-feedback.js +207 -0
- package/leavitt/user-feedback/user-feedback.js.map +1 -0
- package/leavitt/user-manager/LssJwtToken.d.ts +21 -0
- package/leavitt/user-manager/LssJwtToken.js +2 -0
- package/leavitt/user-manager/LssJwtToken.js.map +1 -0
- package/leavitt/user-manager/user-manager-events.d.ts +5 -0
- package/leavitt/user-manager/user-manager-events.js +7 -0
- package/leavitt/user-manager/user-manager-events.js.map +1 -0
- package/leavitt/user-manager/user-manager.d.ts +37 -0
- package/leavitt/user-manager/user-manager.js +364 -0
- package/leavitt/user-manager/user-manager.js.map +1 -0
- package/package.json +36 -0
- package/titanium/access-denied-page/access-denied-page.d.ts +16 -0
- package/titanium/access-denied-page/access-denied-page.js +360 -0
- package/titanium/access-denied-page/access-denied-page.js.map +1 -0
- package/titanium/address-input/Address.js.map +1 -0
- package/titanium/address-input/address-input.d.ts +29 -0
- package/titanium/address-input/address-input.js +77 -0
- package/titanium/address-input/address-input.js.map +1 -0
- package/titanium/address-input/google-address-input.d.ts +30 -0
- package/titanium/address-input/google-address-input.js +202 -0
- package/titanium/address-input/google-address-input.js.map +1 -0
- package/titanium/address-input/manual-address-dialog.d.ts +30 -0
- package/titanium/address-input/manual-address-dialog.js +250 -0
- package/titanium/address-input/manual-address-dialog.js.map +1 -0
- package/titanium/address-input/types/address-input-address.d.ts +17 -0
- package/titanium/address-input/types/address-input-address.js +2 -0
- package/titanium/address-input/types/address-input-address.js.map +1 -0
- package/titanium/address-input/types/address.js.map +1 -0
- package/titanium/address-input/types/autocomplete-prediction-suggestion.js.map +1 -0
- package/titanium/address-input/utils/address-to-string.d.ts +3 -0
- package/titanium/address-input/utils/address-to-string.js +13 -0
- package/titanium/address-input/utils/address-to-string.js.map +1 -0
- package/titanium/address-input/utils/place-result-to-address.d.ts +4 -0
- package/titanium/address-input/utils/place-result-to-address.js +33 -0
- package/titanium/address-input/utils/place-result-to-address.js.map +1 -0
- package/titanium/address-input/utils/validate-street.d.ts +2 -0
- package/titanium/address-input/utils/validate-street.js +8 -0
- package/titanium/address-input/utils/validate-street.js.map +1 -0
- package/titanium/card/card.d.ts +23 -0
- package/titanium/card/card.js +160 -0
- package/titanium/card/card.js.map +1 -0
- package/titanium/chip-multi-select/chip-multi-select.d.ts +55 -0
- package/titanium/chip-multi-select/chip-multi-select.js +119 -0
- package/titanium/chip-multi-select/chip-multi-select.js.map +1 -0
- package/titanium/data-table/data-table-header.d.ts +67 -0
- package/titanium/data-table/data-table-header.js +207 -0
- package/titanium/data-table/data-table-header.js.map +1 -0
- package/titanium/data-table/data-table-item.d.ts +100 -0
- package/titanium/data-table/data-table-item.js +511 -0
- package/titanium/data-table/data-table-item.js.map +1 -0
- package/titanium/data-table/data-table.d.ts +146 -0
- package/titanium/data-table/data-table.js +605 -0
- package/titanium/data-table/data-table.js.map +1 -0
- package/titanium/data-table/filter-controller.d.ts +23 -0
- package/titanium/data-table/filter-controller.js +119 -0
- package/titanium/data-table/filter-controller.js.map +1 -0
- package/titanium/data-table/filter.d.ts +8 -0
- package/titanium/data-table/filter.js +11 -0
- package/titanium/data-table/filter.js.map +1 -0
- package/titanium/data-table/page-control.d.ts +54 -0
- package/titanium/data-table/page-control.js +196 -0
- package/titanium/data-table/page-control.js.map +1 -0
- package/titanium/date-range-selector/date-range-change-event.d.ts +8 -0
- package/titanium/date-range-selector/date-range-change-event.js +10 -0
- package/titanium/date-range-selector/date-range-change-event.js.map +1 -0
- package/titanium/date-range-selector/date-range-selector.d.ts +65 -0
- package/titanium/date-range-selector/date-range-selector.js +423 -0
- package/titanium/date-range-selector/date-range-selector.js.map +1 -0
- package/titanium/date-range-selector/range-label.d.ts +4 -0
- package/titanium/date-range-selector/range-label.js +25 -0
- package/titanium/date-range-selector/range-label.js.map +1 -0
- package/titanium/drawer/drawer.d.ts +39 -0
- package/titanium/drawer/drawer.js +233 -0
- package/titanium/drawer/drawer.js.map +1 -0
- package/titanium/duration-input/duration-input.d.ts +26 -0
- package/titanium/duration-input/duration-input.js +86 -0
- package/titanium/duration-input/duration-input.js.map +1 -0
- package/titanium/duration-input/human-interval.d.ts +19 -0
- package/titanium/duration-input/human-interval.js +74 -0
- package/titanium/duration-input/human-interval.js.map +1 -0
- package/titanium/error-page/error-page.d.ts +16 -0
- package/titanium/error-page/error-page.js +96 -0
- package/titanium/error-page/error-page.js.map +1 -0
- package/titanium/event-bus/event-bus.d.ts +10 -0
- package/titanium/event-bus/event-bus.js +52 -0
- package/titanium/event-bus/event-bus.js.map +1 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.d.ts +160 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.js +295 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.js.map +1 -0
- package/titanium/extendable-outlined-text-field/extensible-outlined-text-field.d.ts +45 -0
- package/titanium/extendable-outlined-text-field/extensible-outlined-text-field.js.map +1 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.d.ts +19 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.js +170 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.js.map +1 -0
- package/titanium/hacks/dialog-overflow-hacks.d.ts +4 -0
- package/titanium/hacks/dialog-overflow-hacks.js +21 -0
- package/titanium/hacks/dialog-overflow-hacks.js.map +1 -0
- package/titanium/header/header.d.ts +39 -0
- package/titanium/header/header.js +148 -0
- package/titanium/header/header.js.map +1 -0
- package/titanium/helpers/csv-download.d.ts +3 -0
- package/titanium/helpers/csv-download.js +78 -0
- package/titanium/helpers/csv-download.js.map +1 -0
- package/titanium/helpers/debouncer.d.ts +13 -0
- package/titanium/helpers/debouncer.js +33 -0
- package/titanium/helpers/debouncer.js.map +1 -0
- package/titanium/helpers/delay.d.ts +2 -0
- package/titanium/helpers/delay.js +6 -0
- package/titanium/helpers/delay.js.map +1 -0
- package/titanium/helpers/dev-detection.d.ts +3 -0
- package/titanium/helpers/dev-detection.js +12 -0
- package/titanium/helpers/dev-detection.js.map +1 -0
- package/titanium/helpers/helpers.d.ts +14 -0
- package/titanium/helpers/helpers.js +14 -0
- package/titanium/helpers/helpers.js.map +1 -0
- package/titanium/helpers/join.d.ts +2 -0
- package/titanium/helpers/join.js +5 -0
- package/titanium/helpers/join.js.map +1 -0
- package/titanium/helpers/leavitt-cdn.d.ts +5 -0
- package/titanium/helpers/leavitt-cdn.js +38 -0
- package/titanium/helpers/leavitt-cdn.js.map +1 -0
- package/titanium/helpers/load-while.d.ts +343 -0
- package/titanium/helpers/load-while.js +27 -0
- package/titanium/helpers/load-while.js.map +1 -0
- package/titanium/helpers/media-query.d.ts +2 -0
- package/titanium/helpers/media-query.js +6 -0
- package/titanium/helpers/media-query.js.map +1 -0
- package/titanium/helpers/middle-ellipsis.d.ts +2 -0
- package/titanium/helpers/middle-ellipsis.js +7 -0
- package/titanium/helpers/middle-ellipsis.js.map +1 -0
- package/titanium/helpers/not-null-or-undefined.d.ts +2 -0
- package/titanium/helpers/not-null-or-undefined.js +4 -0
- package/titanium/helpers/not-null-or-undefined.js.map +1 -0
- package/titanium/helpers/not-null.d.ts +2 -0
- package/titanium/helpers/not-null.js +4 -0
- package/titanium/helpers/not-null.js.map +1 -0
- package/titanium/helpers/not-undefined.d.ts +2 -0
- package/titanium/helpers/not-undefined.js +4 -0
- package/titanium/helpers/not-undefined.js.map +1 -0
- package/titanium/helpers/odata-helpers.d.ts +2 -0
- package/titanium/helpers/odata-helpers.js +2 -0
- package/titanium/helpers/odata-helpers.js.map +1 -0
- package/titanium/helpers/search-token.d.ts +2 -0
- package/titanium/helpers/search-token.js +17 -0
- package/titanium/helpers/search-token.js.map +1 -0
- package/titanium/icon-picker/icon-picker.d.ts +23 -0
- package/titanium/icon-picker/icon-picker.js +75 -0
- package/titanium/icon-picker/icon-picker.js.map +1 -0
- package/titanium/icon-picker/material-symbols.d.ts +3 -0
- package/titanium/icon-picker/material-symbols.js +3297 -0
- package/titanium/icon-picker/material-symbols.js.map +1 -0
- package/titanium/input-validator/input-validator.d.ts +20 -0
- package/titanium/input-validator/input-validator.js +45 -0
- package/titanium/input-validator/input-validator.js.map +1 -0
- package/titanium/search-input/search-input.d.ts +47 -0
- package/titanium/search-input/search-input.js +237 -0
- package/titanium/search-input/search-input.js.map +1 -0
- package/titanium/service-worker-notifier/service-worker-notifier.d.ts +9 -0
- package/titanium/service-worker-notifier/service-worker-notifier.js +57 -0
- package/titanium/service-worker-notifier/service-worker-notifier.js.map +1 -0
- package/titanium/show-hide/show-hide.d.ts +36 -0
- package/titanium/show-hide/show-hide.js +144 -0
- package/titanium/show-hide/show-hide.js.map +1 -0
- package/titanium/single-select-base/single-select-base.d.ts +449 -0
- package/titanium/single-select-base/single-select-base.js +411 -0
- package/titanium/single-select-base/single-select-base.js.map +1 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.d.ts +370 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.js +270 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.js.map +1 -0
- package/titanium/smart-attachment-input/cropper-styles.d.ts +3 -0
- package/titanium/smart-attachment-input/cropper-styles.js +311 -0
- package/titanium/smart-attachment-input/cropper-styles.js.map +1 -0
- package/titanium/smart-attachment-input/image-formats.d.ts +5 -0
- package/titanium/smart-attachment-input/image-formats.js +37 -0
- package/titanium/smart-attachment-input/image-formats.js.map +1 -0
- package/titanium/smart-attachment-input/image-preview-dialog.d.ts +21 -0
- package/titanium/smart-attachment-input/image-preview-dialog.js +83 -0
- package/titanium/smart-attachment-input/image-preview-dialog.js.map +1 -0
- package/titanium/smart-attachment-input/smart-attachment-input.d.ts +126 -0
- package/titanium/smart-attachment-input/smart-attachment-input.js +422 -0
- package/titanium/smart-attachment-input/smart-attachment-input.js.map +1 -0
- package/titanium/smart-attachment-input/type/smart-attachment.d.ts +7 -0
- package/titanium/smart-attachment-input/type/smart-attachment.js +2 -0
- package/titanium/smart-attachment-input/type/smart-attachment.js.map +1 -0
- package/titanium/snackbar/snackbar.d.ts +79 -0
- package/titanium/snackbar/snackbar.js +302 -0
- package/titanium/snackbar/snackbar.js.map +1 -0
- package/titanium/styles/a.d.ts +2 -0
- package/titanium/styles/a.js +18 -0
- package/titanium/styles/a.js.map +1 -0
- package/titanium/styles/data-row.d.ts +2 -0
- package/titanium/styles/data-row.js +52 -0
- package/titanium/styles/data-row.js.map +1 -0
- package/titanium/styles/ellipsis.d.ts +2 -0
- package/titanium/styles/ellipsis.js +9 -0
- package/titanium/styles/ellipsis.js.map +1 -0
- package/titanium/styles/h1.d.ts +2 -0
- package/titanium/styles/h1.js +17 -0
- package/titanium/styles/h1.js.map +1 -0
- package/titanium/styles/h2.d.ts +2 -0
- package/titanium/styles/h2.js +17 -0
- package/titanium/styles/h2.js.map +1 -0
- package/titanium/styles/h3.d.ts +2 -0
- package/titanium/styles/h3.js +17 -0
- package/titanium/styles/h3.js.map +1 -0
- package/titanium/styles/h4.d.ts +2 -0
- package/titanium/styles/h4.js +17 -0
- package/titanium/styles/h4.js.map +1 -0
- package/titanium/styles/h5.d.ts +2 -0
- package/titanium/styles/h5.js +19 -0
- package/titanium/styles/h5.js.map +1 -0
- package/titanium/styles/p.d.ts +2 -0
- package/titanium/styles/p.js +17 -0
- package/titanium/styles/p.js.map +1 -0
- package/titanium/styles/styles.d.ts +17 -0
- package/titanium/styles/styles.js +17 -0
- package/titanium/styles/styles.js.map +1 -0
- package/titanium/toolbar/toolbar.d.ts +34 -0
- package/titanium/toolbar/toolbar.js +104 -0
- package/titanium/toolbar/toolbar.js.map +1 -0
- package/titanium/types/any-function.d.ts +5 -0
- package/titanium/types/any-function.js +2 -0
- package/titanium/types/any-function.js.map +1 -0
- package/titanium/types/dom-event.d.ts +4 -0
- package/titanium/types/dom-event.js +2 -0
- package/titanium/types/dom-event.js.map +1 -0
- package/titanium/types/identifier-interface.d.ts +4 -0
- package/titanium/types/identifier-interface.js +2 -0
- package/titanium/types/identifier-interface.js.map +1 -0
- package/titanium/types/pending-state-event.d.ts +7 -0
- package/titanium/types/pending-state-event.js +7 -0
- package/titanium/types/pending-state-event.js.map +1 -0
- package/titanium/types/string-map.d.ts +7 -0
- package/titanium/types/string-map.js +5 -0
- package/titanium/types/string-map.js.map +1 -0
- package/titanium/youtube-input/youtube-input.d.ts +17 -0
- package/titanium/youtube-input/youtube-input.js +52 -0
- package/titanium/youtube-input/youtube-input.js.map +1 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import '@material/web/elevation/elevation';
|
|
2
|
+
import { LitElement } from 'lit';
|
|
3
|
+
/**
|
|
4
|
+
* A material card filled or outlined
|
|
5
|
+
*
|
|
6
|
+
* @element titanium-card
|
|
7
|
+
*
|
|
8
|
+
* @cssprop {Number} [--md-elevation-level: 0] - Use md elevation to set elevation levels
|
|
9
|
+
* @cssprop {Color} [--md-elevation-shadow-color: --md-sys-color-shadow] - Use md elevation to set elevation levels
|
|
10
|
+
* @cssprop {Color} [--md-sys-color-outline-variant] - Card border color
|
|
11
|
+
*
|
|
12
|
+
* @slot Default - Card content
|
|
13
|
+
*/
|
|
14
|
+
export declare class TitaniumCard extends LitElement {
|
|
15
|
+
hasMenu: boolean;
|
|
16
|
+
hasImage: boolean;
|
|
17
|
+
hasFooter: boolean;
|
|
18
|
+
primary: boolean;
|
|
19
|
+
surface: boolean;
|
|
20
|
+
static styles: import("lit").CSSResult[];
|
|
21
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=card.d.ts.map
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import '@material/web/elevation/elevation';
|
|
3
|
+
import { css, html, LitElement } from 'lit';
|
|
4
|
+
import { property, customElement } from 'lit/decorators.js';
|
|
5
|
+
/**
|
|
6
|
+
* A material card filled or outlined
|
|
7
|
+
*
|
|
8
|
+
* @element titanium-card
|
|
9
|
+
*
|
|
10
|
+
* @cssprop {Number} [--md-elevation-level: 0] - Use md elevation to set elevation levels
|
|
11
|
+
* @cssprop {Color} [--md-elevation-shadow-color: --md-sys-color-shadow] - Use md elevation to set elevation levels
|
|
12
|
+
* @cssprop {Color} [--md-sys-color-outline-variant] - Card border color
|
|
13
|
+
*
|
|
14
|
+
* @slot Default - Card content
|
|
15
|
+
*/
|
|
16
|
+
let TitaniumCard = class TitaniumCard extends LitElement {
|
|
17
|
+
static { this.styles = [
|
|
18
|
+
css `
|
|
19
|
+
:host {
|
|
20
|
+
display: grid;
|
|
21
|
+
padding: 24px;
|
|
22
|
+
gap: 8px 12px;
|
|
23
|
+
grid:
|
|
24
|
+
'title' auto
|
|
25
|
+
'body' 1fr;
|
|
26
|
+
border-radius: 12px;
|
|
27
|
+
position: relative;
|
|
28
|
+
|
|
29
|
+
border: 1px solid var(--md-sys-color-outline-variant);
|
|
30
|
+
background-color: var(--md-sys-color-surface);
|
|
31
|
+
color: var(--md-sys-color-on-surface);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
:host([primary]) {
|
|
35
|
+
border: none;
|
|
36
|
+
background-color: var(--md-sys-color-primary-container);
|
|
37
|
+
color: var(--md-sys-color-on-primary-container);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
:host([surface]) {
|
|
41
|
+
border: none;
|
|
42
|
+
background-color: var(--md-sys-color-surface-variant);
|
|
43
|
+
color: var(--md-sys-color-on-surface-variant);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
:host([has-menu]) {
|
|
47
|
+
grid:
|
|
48
|
+
'title menu' auto
|
|
49
|
+
'body body' 1fr / 1fr auto;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
:host([has-footer]) {
|
|
53
|
+
grid:
|
|
54
|
+
'title' auto
|
|
55
|
+
'body' 1fr
|
|
56
|
+
'footer' auto;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
:host([has-footer][has-menu]) {
|
|
60
|
+
grid:
|
|
61
|
+
'title menu' min-content
|
|
62
|
+
'body body' 1fr
|
|
63
|
+
'footer footer' auto / 1fr auto;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
:host([has-image]) {
|
|
67
|
+
grid:
|
|
68
|
+
'title image' min-content
|
|
69
|
+
'body image' 1fr / 1fr auto;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
:host([has-image][has-footer]) {
|
|
73
|
+
grid:
|
|
74
|
+
'title image' min-content
|
|
75
|
+
'body image' 1fr
|
|
76
|
+
'footer footer' auto / 1fr auto;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
:host([has-image][has-footer][has-menu]) {
|
|
80
|
+
grid:
|
|
81
|
+
'title menu' min-content
|
|
82
|
+
'body image' 1fr
|
|
83
|
+
'footer footer' auto / 1fr auto;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
::slotted([card-menu]) {
|
|
87
|
+
grid-area: menu;
|
|
88
|
+
justify-self: right;
|
|
89
|
+
margin: -12px -12px -12px 0;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
::slotted([card-title]) {
|
|
93
|
+
grid-area: title;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
::slotted([card-body]) {
|
|
97
|
+
grid-area: body;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
::slotted([card-image]) {
|
|
101
|
+
grid-area: image;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
::slotted([full-width]) {
|
|
105
|
+
margin: 0 -24px;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
::slotted([card-footer]) {
|
|
109
|
+
grid-area: footer;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
::slotted([nav]) {
|
|
113
|
+
margin: 16px -12px -12px 0;
|
|
114
|
+
justify-self: right;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
@media (max-width: 400px) {
|
|
118
|
+
::slotted([card-image]) {
|
|
119
|
+
display: none;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
:host([has-image][has-footer]) {
|
|
123
|
+
grid:
|
|
124
|
+
'title' min-content
|
|
125
|
+
'body' auto
|
|
126
|
+
'footer' 1fr / auto;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
:host([has-image]) {
|
|
130
|
+
grid:
|
|
131
|
+
'title' min-content
|
|
132
|
+
'body' auto / auto;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
`,
|
|
136
|
+
]; }
|
|
137
|
+
render() {
|
|
138
|
+
return html `<md-elevation></md-elevation> <slot></slot> `;
|
|
139
|
+
}
|
|
140
|
+
};
|
|
141
|
+
__decorate([
|
|
142
|
+
property({ type: Boolean, reflect: true, attribute: 'has-menu' })
|
|
143
|
+
], TitaniumCard.prototype, "hasMenu", void 0);
|
|
144
|
+
__decorate([
|
|
145
|
+
property({ type: Boolean, reflect: true, attribute: 'has-image' })
|
|
146
|
+
], TitaniumCard.prototype, "hasImage", void 0);
|
|
147
|
+
__decorate([
|
|
148
|
+
property({ type: Boolean, reflect: true, attribute: 'has-footer' })
|
|
149
|
+
], TitaniumCard.prototype, "hasFooter", void 0);
|
|
150
|
+
__decorate([
|
|
151
|
+
property({ type: Boolean, reflect: true, attribute: 'primary' })
|
|
152
|
+
], TitaniumCard.prototype, "primary", void 0);
|
|
153
|
+
__decorate([
|
|
154
|
+
property({ type: Boolean, reflect: true, attribute: 'surface' })
|
|
155
|
+
], TitaniumCard.prototype, "surface", void 0);
|
|
156
|
+
TitaniumCard = __decorate([
|
|
157
|
+
customElement('titanium-card')
|
|
158
|
+
], TitaniumCard);
|
|
159
|
+
export { TitaniumCard };
|
|
160
|
+
//# sourceMappingURL=card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"card.js","sourceRoot":"","sources":["card.ts"],"names":[],"mappings":";AAAA,OAAO,mCAAmC,CAAC;AAE3C,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAE5D;;;;;;;;;;GAUG;AAEI,IAAM,YAAY,GAAlB,MAAM,YAAa,SAAQ,UAAU;aAOnC,WAAM,GAAG;QACd,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAqHF;KACF,AAvHY,CAuHX;IAEF,MAAM;QACJ,OAAO,IAAI,CAAA,8CAA8C,CAAC;IAC5D,CAAC;;AAjIkE;IAAlE,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,CAAC;6CAAkB;AAChB;IAAnE,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,CAAC;8CAAmB;AACjB;IAApE,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;+CAAoB;AACtB;IAAjE,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;6CAAkB;AACjB;IAAjE,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;6CAAkB;AALxE,YAAY;IADxB,aAAa,CAAC,eAAe,CAAC;GAClB,YAAY,CAmIxB"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { LitElement, PropertyValues } from 'lit';
|
|
2
|
+
import { TitaniumInputValidator } from '../../titanium/input-validator/input-validator';
|
|
3
|
+
import '../../titanium/input-validator/input-validator';
|
|
4
|
+
/**
|
|
5
|
+
* Multi select outlined themed input that styles
|
|
6
|
+
* slotted in chips and add button
|
|
7
|
+
*
|
|
8
|
+
* @element titanium-chip-multi-select
|
|
9
|
+
*
|
|
10
|
+
* @slot default - Main slot (intended to be a <md-outlined-button> and a list of <md-chip>)
|
|
11
|
+
*
|
|
12
|
+
*/
|
|
13
|
+
export declare class TitaniumChipMultiSelect extends LitElement {
|
|
14
|
+
/**
|
|
15
|
+
* Label of input to display to users
|
|
16
|
+
*/
|
|
17
|
+
label: string;
|
|
18
|
+
/**
|
|
19
|
+
* Text to show when there are no items
|
|
20
|
+
*/
|
|
21
|
+
noItemsText: string;
|
|
22
|
+
/**
|
|
23
|
+
* Adds the * to the label
|
|
24
|
+
*/
|
|
25
|
+
required: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* Indicates whether or not to show the no items text
|
|
28
|
+
*/
|
|
29
|
+
hasItems: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Sets supporting text
|
|
32
|
+
*/
|
|
33
|
+
supportingText: string;
|
|
34
|
+
/**
|
|
35
|
+
* Whether or not the input should appear disabled (chips, buttons and anything else slotted will still have to be disabled individually).
|
|
36
|
+
*/
|
|
37
|
+
disabled: boolean;
|
|
38
|
+
validator: TitaniumInputValidator;
|
|
39
|
+
updated(changedProps: PropertyValues<this>): void;
|
|
40
|
+
/**
|
|
41
|
+
* Returns true if the input passes validity checks.
|
|
42
|
+
*/
|
|
43
|
+
checkValidity(): boolean;
|
|
44
|
+
/**
|
|
45
|
+
* Runs checkValidity() method, and if it returns false, then it reports to the user that the input is invalid.
|
|
46
|
+
*/
|
|
47
|
+
reportValidity(): boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Resets the inputs state.
|
|
50
|
+
*/
|
|
51
|
+
reset(): void;
|
|
52
|
+
static styles: import("lit").CSSResult[];
|
|
53
|
+
protected render(): import("lit-html").TemplateResult<1>;
|
|
54
|
+
}
|
|
55
|
+
//# sourceMappingURL=chip-multi-select.d.ts.map
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { css, html, LitElement } from 'lit';
|
|
3
|
+
import { customElement, property, query } from 'lit/decorators.js';
|
|
4
|
+
import '../../titanium/input-validator/input-validator';
|
|
5
|
+
/**
|
|
6
|
+
* Multi select outlined themed input that styles
|
|
7
|
+
* slotted in chips and add button
|
|
8
|
+
*
|
|
9
|
+
* @element titanium-chip-multi-select
|
|
10
|
+
*
|
|
11
|
+
* @slot default - Main slot (intended to be a <md-outlined-button> and a list of <md-chip>)
|
|
12
|
+
*
|
|
13
|
+
*/
|
|
14
|
+
let TitaniumChipMultiSelect = class TitaniumChipMultiSelect extends LitElement {
|
|
15
|
+
constructor() {
|
|
16
|
+
super(...arguments);
|
|
17
|
+
/**
|
|
18
|
+
* Text to show when there are no items
|
|
19
|
+
*/
|
|
20
|
+
this.noItemsText = 'No items';
|
|
21
|
+
/**
|
|
22
|
+
* Adds the * to the label
|
|
23
|
+
*/
|
|
24
|
+
this.required = false;
|
|
25
|
+
}
|
|
26
|
+
updated(changedProps) {
|
|
27
|
+
if ((changedProps.get('hasItems') && changedProps.has('hasItems')) || (this.hasItems && changedProps.has('hasItems'))) {
|
|
28
|
+
this.reportValidity();
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Returns true if the input passes validity checks.
|
|
33
|
+
*/
|
|
34
|
+
checkValidity() {
|
|
35
|
+
return this.validator.checkValidity();
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Runs checkValidity() method, and if it returns false, then it reports to the user that the input is invalid.
|
|
39
|
+
*/
|
|
40
|
+
reportValidity() {
|
|
41
|
+
return this.validator.reportValidity();
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Resets the inputs state.
|
|
45
|
+
*/
|
|
46
|
+
reset() {
|
|
47
|
+
this.validator.reset();
|
|
48
|
+
}
|
|
49
|
+
static { this.styles = [
|
|
50
|
+
css `
|
|
51
|
+
:host {
|
|
52
|
+
display: block;
|
|
53
|
+
width: 100%;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
titanium-input-validator {
|
|
57
|
+
display: block;
|
|
58
|
+
width: 100%;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
slot-container {
|
|
62
|
+
display: flex;
|
|
63
|
+
flex-wrap: wrap;
|
|
64
|
+
grid-gap: 12px;
|
|
65
|
+
align-items: center;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
::slotted(md-outlined-button) {
|
|
69
|
+
line-height: 0;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
span {
|
|
73
|
+
font-size: 13px;
|
|
74
|
+
}
|
|
75
|
+
`,
|
|
76
|
+
]; }
|
|
77
|
+
render() {
|
|
78
|
+
return html `
|
|
79
|
+
<titanium-input-validator
|
|
80
|
+
?disabled=${this.disabled}
|
|
81
|
+
.evaluator=${() => !this.required || !!this.hasItems}
|
|
82
|
+
?required=${this.required}
|
|
83
|
+
.label=${this.label}
|
|
84
|
+
.supportingText=${this.supportingText}
|
|
85
|
+
>
|
|
86
|
+
<slot-container>
|
|
87
|
+
<slot></slot>
|
|
88
|
+
${!this.hasItems ? html ` <span>${this.noItemsText}</span>` : ''}
|
|
89
|
+
</slot-container>
|
|
90
|
+
</titanium-input-validator>
|
|
91
|
+
`;
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
__decorate([
|
|
95
|
+
property({ type: String })
|
|
96
|
+
], TitaniumChipMultiSelect.prototype, "label", void 0);
|
|
97
|
+
__decorate([
|
|
98
|
+
property({ type: String })
|
|
99
|
+
], TitaniumChipMultiSelect.prototype, "noItemsText", void 0);
|
|
100
|
+
__decorate([
|
|
101
|
+
property({ type: Boolean })
|
|
102
|
+
], TitaniumChipMultiSelect.prototype, "required", void 0);
|
|
103
|
+
__decorate([
|
|
104
|
+
property({ type: Boolean })
|
|
105
|
+
], TitaniumChipMultiSelect.prototype, "hasItems", void 0);
|
|
106
|
+
__decorate([
|
|
107
|
+
property({ type: String })
|
|
108
|
+
], TitaniumChipMultiSelect.prototype, "supportingText", void 0);
|
|
109
|
+
__decorate([
|
|
110
|
+
property({ type: Boolean, reflect: true })
|
|
111
|
+
], TitaniumChipMultiSelect.prototype, "disabled", void 0);
|
|
112
|
+
__decorate([
|
|
113
|
+
query('titanium-input-validator')
|
|
114
|
+
], TitaniumChipMultiSelect.prototype, "validator", void 0);
|
|
115
|
+
TitaniumChipMultiSelect = __decorate([
|
|
116
|
+
customElement('titanium-chip-multi-select')
|
|
117
|
+
], TitaniumChipMultiSelect);
|
|
118
|
+
export { TitaniumChipMultiSelect };
|
|
119
|
+
//# sourceMappingURL=chip-multi-select.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chip-multi-select.js","sourceRoot":"","sources":["chip-multi-select.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAkB,MAAM,K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WAAW,SAAS,CAAC,CAAC,CAAC,EAAE;;;KAGpE,CAAC;IACJ,CAAC;;AApG2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;sDAAe;AAKd;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;4DAAkC;AAKhC;IAA5B,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;yDAA2B;AAK1B;IAA5B,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;yDAAmB;AAKnB;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+DAAwB;AAKP;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;yDAAmB;AAE3B;IAAlC,KAAK,CAAC,0BAA0B,CAAC;0DAAmC;AA/B1D,uBAAuB;IADnC,aAAa,CAAC,4BAA4B,CAAC;GAC/B,uBAAuB,CAyGnC"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
import '@material/web/icon/icon';
|
|
3
|
+
/**
|
|
4
|
+
* Material design data table header with styling and sorting capabilities
|
|
5
|
+
*
|
|
6
|
+
* @element titanium-data-table-header
|
|
7
|
+
*
|
|
8
|
+
* @fires sort-direction-changed - Fired if sort direction is changed (detail: 'desc' | 'asc')
|
|
9
|
+
* @fires sort-by-changed - Fired when the close button is clicked (detail: {string} column name of currently sorted header )
|
|
10
|
+
*
|
|
11
|
+
* @cssprop {font} [--titanium-data-table-font-family=Roboto, Noto, sans-serif] - Font family
|
|
12
|
+
*/
|
|
13
|
+
export declare class TitaniumDataTableHeader extends LitElement {
|
|
14
|
+
/**
|
|
15
|
+
* This displayed header name
|
|
16
|
+
*/
|
|
17
|
+
title: string;
|
|
18
|
+
/**
|
|
19
|
+
* The column name of the currently applied sort
|
|
20
|
+
*/
|
|
21
|
+
sortBy: string;
|
|
22
|
+
/**
|
|
23
|
+
* Optional fixed width of header in px ex. "140px"
|
|
24
|
+
*/
|
|
25
|
+
width: string;
|
|
26
|
+
/**
|
|
27
|
+
* True if header is currently the sorted column. Read-only, do not set.
|
|
28
|
+
*/
|
|
29
|
+
active: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Current sort direction on header.
|
|
32
|
+
*/
|
|
33
|
+
sortDirection: 'asc' | 'desc' | '';
|
|
34
|
+
/**
|
|
35
|
+
* Name of header column passed along in sort-by-changed event. Typically the name of the col in the backing DB. ex. first_name
|
|
36
|
+
*/
|
|
37
|
+
columnName: string;
|
|
38
|
+
/**
|
|
39
|
+
* Justify header text center
|
|
40
|
+
*/
|
|
41
|
+
center: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Justify header text right; moves sort icon to left.
|
|
44
|
+
*/
|
|
45
|
+
right: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Removes the sort icon
|
|
48
|
+
*/
|
|
49
|
+
noSort: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Set flex 5 on header, default is 3.
|
|
52
|
+
*/
|
|
53
|
+
large: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Only show this header when width is larger
|
|
56
|
+
*/
|
|
57
|
+
desktop: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Sets if view port is small
|
|
60
|
+
*/
|
|
61
|
+
narrow: boolean;
|
|
62
|
+
updated(changedProps: any): void;
|
|
63
|
+
firstUpdated(): void;
|
|
64
|
+
static styles: import("lit").CSSResult;
|
|
65
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
66
|
+
}
|
|
67
|
+
//# sourceMappingURL=data-table-header.d.ts.map
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { css, html, LitElement } from 'lit';
|
|
3
|
+
import { property, customElement } from 'lit/decorators.js';
|
|
4
|
+
import '@material/web/icon/icon';
|
|
5
|
+
/**
|
|
6
|
+
* Material design data table header with styling and sorting capabilities
|
|
7
|
+
*
|
|
8
|
+
* @element titanium-data-table-header
|
|
9
|
+
*
|
|
10
|
+
* @fires sort-direction-changed - Fired if sort direction is changed (detail: 'desc' | 'asc')
|
|
11
|
+
* @fires sort-by-changed - Fired when the close button is clicked (detail: {string} column name of currently sorted header )
|
|
12
|
+
*
|
|
13
|
+
* @cssprop {font} [--titanium-data-table-font-family=Roboto, Noto, sans-serif] - Font family
|
|
14
|
+
*/
|
|
15
|
+
let TitaniumDataTableHeader = class TitaniumDataTableHeader extends LitElement {
|
|
16
|
+
constructor() {
|
|
17
|
+
super(...arguments);
|
|
18
|
+
/**
|
|
19
|
+
* True if header is currently the sorted column. Read-only, do not set.
|
|
20
|
+
*/
|
|
21
|
+
this.active = false;
|
|
22
|
+
/**
|
|
23
|
+
* Justify header text center
|
|
24
|
+
*/
|
|
25
|
+
this.center = false;
|
|
26
|
+
/**
|
|
27
|
+
* Justify header text right; moves sort icon to left.
|
|
28
|
+
*/
|
|
29
|
+
this.right = false;
|
|
30
|
+
/**
|
|
31
|
+
* Removes the sort icon
|
|
32
|
+
*/
|
|
33
|
+
this.noSort = false;
|
|
34
|
+
/**
|
|
35
|
+
* Set flex 5 on header, default is 3.
|
|
36
|
+
*/
|
|
37
|
+
this.large = false;
|
|
38
|
+
/**
|
|
39
|
+
* Only show this header when width is larger
|
|
40
|
+
*/
|
|
41
|
+
this.desktop = false;
|
|
42
|
+
/**
|
|
43
|
+
* Sets if view port is small
|
|
44
|
+
*/
|
|
45
|
+
this.narrow = false;
|
|
46
|
+
}
|
|
47
|
+
updated(changedProps) {
|
|
48
|
+
if (changedProps.has('sortBy') && changedProps.get('sortBy') !== this.sortBy) {
|
|
49
|
+
this.active = this.sortBy === this.columnName;
|
|
50
|
+
}
|
|
51
|
+
if (changedProps.has('width') && changedProps.get('width') !== this.width && this.width) {
|
|
52
|
+
this.style.width = this.width;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
firstUpdated() {
|
|
56
|
+
this.addEventListener('click', () => {
|
|
57
|
+
if (this.active) {
|
|
58
|
+
this.sortDirection = this.sortDirection === 'asc' ? 'desc' : 'asc';
|
|
59
|
+
this.dispatchEvent(new CustomEvent('sort-direction-changed', { detail: this.sortDirection }));
|
|
60
|
+
}
|
|
61
|
+
else {
|
|
62
|
+
this.sortBy = this.columnName;
|
|
63
|
+
this.dispatchEvent(new CustomEvent('sort-by-changed', { detail: this.sortBy }));
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
static { this.styles = css `
|
|
68
|
+
:host {
|
|
69
|
+
display: inline-flex;
|
|
70
|
+
flex-direction: row;
|
|
71
|
+
align-items: center;
|
|
72
|
+
|
|
73
|
+
-webkit-touch-callout: none;
|
|
74
|
+
-webkit-user-select: none;
|
|
75
|
+
-khtml-user-select: none;
|
|
76
|
+
-moz-user-select: none;
|
|
77
|
+
-ms-user-select: none;
|
|
78
|
+
user-select: none;
|
|
79
|
+
|
|
80
|
+
cursor: pointer;
|
|
81
|
+
|
|
82
|
+
font-family: var(--titanium-data-table-font-family, Roboto, Noto, sans-serif);
|
|
83
|
+
-webkit-font-smoothing: antialiased;
|
|
84
|
+
font-size: 14px;
|
|
85
|
+
padding: 8px;
|
|
86
|
+
line-height: 28px;
|
|
87
|
+
font-weight: 500;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
:host(:not([width])) {
|
|
91
|
+
-ms-flex: 3;
|
|
92
|
+
-webkit-flex: 3;
|
|
93
|
+
flex: 3;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
:host(:not([width])[large]) {
|
|
97
|
+
-ms-flex: 5;
|
|
98
|
+
-webkit-flex: 5;
|
|
99
|
+
flex: 5;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
:host([hidden]) {
|
|
103
|
+
display: none;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
:host([no-sort]) {
|
|
107
|
+
cursor: inherit;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
:host([center]) {
|
|
111
|
+
justify-content: center;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
:host([center])::before {
|
|
115
|
+
width: 18px;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
:host([right]) {
|
|
119
|
+
flex-direction: row-reverse;
|
|
120
|
+
text-align: right;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
md-icon {
|
|
124
|
+
display: block;
|
|
125
|
+
height: 18px;
|
|
126
|
+
width: 18px;
|
|
127
|
+
font-size: 18px;
|
|
128
|
+
margin-left: 4px;
|
|
129
|
+
flex-shrink: 0;
|
|
130
|
+
transform-origin: center;
|
|
131
|
+
transition: transform 150ms ease;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
:host([no-sort]) md-icon {
|
|
135
|
+
display: none;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
:host([right]) md-icon {
|
|
139
|
+
margin-right: 4px;
|
|
140
|
+
margin-left: 0;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
md-icon {
|
|
144
|
+
visibility: hidden;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
:host([active][sort-direction='asc']) md-icon {
|
|
148
|
+
transform: rotate(-180deg);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
:host([active][sort-direction='asc']) md-icon,
|
|
152
|
+
:host([active][sort-direction='desc']) md-icon {
|
|
153
|
+
visibility: visible;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
:host([narrow][desktop]) {
|
|
157
|
+
display: none;
|
|
158
|
+
}
|
|
159
|
+
`; }
|
|
160
|
+
render() {
|
|
161
|
+
return html `
|
|
162
|
+
${this.title}
|
|
163
|
+
<md-icon>arrow_downward</md-icon>
|
|
164
|
+
`;
|
|
165
|
+
}
|
|
166
|
+
};
|
|
167
|
+
__decorate([
|
|
168
|
+
property({ type: String })
|
|
169
|
+
], TitaniumDataTableHeader.prototype, "title", void 0);
|
|
170
|
+
__decorate([
|
|
171
|
+
property({ type: String })
|
|
172
|
+
], TitaniumDataTableHeader.prototype, "sortBy", void 0);
|
|
173
|
+
__decorate([
|
|
174
|
+
property({ reflect: true, type: String })
|
|
175
|
+
], TitaniumDataTableHeader.prototype, "width", void 0);
|
|
176
|
+
__decorate([
|
|
177
|
+
property({ type: Boolean, reflect: true })
|
|
178
|
+
], TitaniumDataTableHeader.prototype, "active", void 0);
|
|
179
|
+
__decorate([
|
|
180
|
+
property({ type: String, reflect: true, attribute: 'sort-direction' })
|
|
181
|
+
], TitaniumDataTableHeader.prototype, "sortDirection", void 0);
|
|
182
|
+
__decorate([
|
|
183
|
+
property({ type: String, attribute: 'column-name' })
|
|
184
|
+
], TitaniumDataTableHeader.prototype, "columnName", void 0);
|
|
185
|
+
__decorate([
|
|
186
|
+
property({ type: Boolean, reflect: true })
|
|
187
|
+
], TitaniumDataTableHeader.prototype, "center", void 0);
|
|
188
|
+
__decorate([
|
|
189
|
+
property({ type: Boolean, reflect: true })
|
|
190
|
+
], TitaniumDataTableHeader.prototype, "right", void 0);
|
|
191
|
+
__decorate([
|
|
192
|
+
property({ type: Boolean, reflect: true, attribute: 'no-sort' })
|
|
193
|
+
], TitaniumDataTableHeader.prototype, "noSort", void 0);
|
|
194
|
+
__decorate([
|
|
195
|
+
property({ type: Boolean, reflect: true })
|
|
196
|
+
], TitaniumDataTableHeader.prototype, "large", void 0);
|
|
197
|
+
__decorate([
|
|
198
|
+
property({ type: Boolean, reflect: true })
|
|
199
|
+
], TitaniumDataTableHeader.prototype, "desktop", void 0);
|
|
200
|
+
__decorate([
|
|
201
|
+
property({ type: Boolean, reflect: true })
|
|
202
|
+
], TitaniumDataTableHeader.prototype, "narrow", void 0);
|
|
203
|
+
TitaniumDataTableHeader = __decorate([
|
|
204
|
+
customElement('titanium-data-table-header')
|
|
205
|
+
], TitaniumDataTableHeader);
|
|
206
|
+
export { TitaniumDataTableHeader };
|
|
207
|
+
//# sourceMappingURL=data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