@aquera/nile-elements 0.0.85 → 0.0.87

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.
Files changed (37) hide show
  1. package/README.md +6 -0
  2. package/dist/index.cjs.js +1 -1
  3. package/dist/index.esm.js +1 -1
  4. package/dist/index.iife.js +10 -1
  5. package/dist/nile-calendar/nile-calendar.css.cjs.js +1 -1
  6. package/dist/nile-calendar/nile-calendar.css.cjs.js.map +1 -1
  7. package/dist/nile-calendar/nile-calendar.css.esm.js +5 -0
  8. package/dist/nile-title/index.cjs.js +2 -0
  9. package/dist/nile-title/index.cjs.js.map +1 -0
  10. package/dist/nile-title/index.esm.js +1 -0
  11. package/dist/nile-title/nile-title.cjs.js +2 -0
  12. package/dist/nile-title/nile-title.cjs.js.map +1 -0
  13. package/dist/nile-title/nile-title.css.cjs.js +2 -0
  14. package/dist/nile-title/nile-title.css.cjs.js.map +1 -0
  15. package/dist/nile-title/nile-title.css.esm.js +5 -0
  16. package/dist/nile-title/nile-title.esm.js +1 -0
  17. package/dist/src/index.d.ts +1 -0
  18. package/dist/src/index.js +1 -0
  19. package/dist/src/index.js.map +1 -1
  20. package/dist/src/nile-calendar/nile-calendar.css.js +5 -0
  21. package/dist/src/nile-calendar/nile-calendar.css.js.map +1 -1
  22. package/dist/src/nile-title/index.d.ts +1 -0
  23. package/dist/src/nile-title/index.js +2 -0
  24. package/dist/src/nile-title/index.js.map +1 -0
  25. package/dist/src/nile-title/nile-title.css.d.ts +12 -0
  26. package/dist/src/nile-title/nile-title.css.js +17 -0
  27. package/dist/src/nile-title/nile-title.css.js.map +1 -0
  28. package/dist/src/nile-title/nile-title.d.ts +42 -0
  29. package/dist/src/nile-title/nile-title.js +66 -0
  30. package/dist/src/nile-title/nile-title.js.map +1 -0
  31. package/dist/tsconfig.tsbuildinfo +1 -1
  32. package/package.json +3 -2
  33. package/src/index.ts +1 -0
  34. package/src/nile-calendar/nile-calendar.css.ts +5 -0
  35. package/src/nile-title/index.ts +1 -0
  36. package/src/nile-title/nile-title.css.ts +19 -0
  37. package/src/nile-title/nile-title.ts +69 -0
@@ -0,0 +1,66 @@
1
+ /**
2
+ * Copyright Aquera Inc 2023
3
+ *
4
+ * This source code is licensed under the BSD-3-Clause license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import { __decorate } from "tslib";
8
+ import { html, property } from 'lit-element';
9
+ import { customElement } from 'lit/decorators.js';
10
+ import { styles } from './nile-title.css';
11
+ import NileElement from '../internal/nile-element';
12
+ /**
13
+ * Nile title component.
14
+ *
15
+ * @tag nile-title
16
+ *
17
+ */
18
+ let NileTitle = class NileTitle extends NileElement {
19
+ constructor() {
20
+ super(...arguments);
21
+ this.headerText = '';
22
+ this.pageTitle = '';
23
+ /* #endregion */
24
+ }
25
+ /**
26
+ * The styles for nile-title
27
+ * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`
28
+ */
29
+ static get styles() {
30
+ return [styles];
31
+ }
32
+ /* #endregion */
33
+ /* #region Methods */
34
+ /**
35
+ * Called when the component is updated
36
+ */
37
+ updated(_changedProperties) {
38
+ super.updated(_changedProperties);
39
+ this.updateDocumentTitle();
40
+ }
41
+ /**
42
+ * Updates the document title based on pageTitle or headerText
43
+ */
44
+ updateDocumentTitle() {
45
+ document.title = this.pageTitle || this.headerText;
46
+ }
47
+ /**
48
+ * Render method
49
+ * @slot This is a slot test
50
+ */
51
+ render() {
52
+ return html ` ${this.headerText ? html ` ${this.headerText} ` : ''} `;
53
+ }
54
+ };
55
+ __decorate([
56
+ property({ type: String })
57
+ ], NileTitle.prototype, "headerText", void 0);
58
+ __decorate([
59
+ property({ type: String })
60
+ ], NileTitle.prototype, "pageTitle", void 0);
61
+ NileTitle = __decorate([
62
+ customElement('nile-title')
63
+ ], NileTitle);
64
+ export { NileTitle };
65
+ export default NileTitle;
66
+ //# sourceMappingURL=nile-title.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"n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A2CtB,eAAe,SAAS,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {LitElement, html, property, CSSResultArray, TemplateResult} from 'lit-element';\nimport { customElement } from 'lit/decorators.js';\nimport {styles} from './nile-title.css';\nimport NileElement from '../internal/nile-element';\n\n/**\n * Nile title component.\n *\n * @tag nile-title\n *\n */\n@customElement('nile-title')\nexport class NileTitle extends NileElement {\n @property({ type: String }) headerText = '';\n\n @property({ type: String }) pageTitle = '';\n\n /**\n * The styles for nile-title\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n /* #endregion */\n\n /* #region Methods */\n\n /**\n * Called when the component is updated\n */\n protected updated(_changedProperties: Map<string | number | symbol, unknown>): void {\n super.updated(_changedProperties);\n this.updateDocumentTitle();\n }\n\n /**\n * Updates the document title based on pageTitle or headerText\n */\n private updateDocumentTitle(): void {\n document.title = this.pageTitle || this.headerText;\n }\n\n /**\n * Render method\n * @slot This is a slot test\n */\n public render(): TemplateResult {\n return html` ${this.headerText ? html` ${this.headerText} ` : ''} `;\n }\n\n /* #endregion */\n}\n\nexport default NileTitle;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-title': NileTitle;\n }\n}\n"]}