@progressive-development/pd-page 0.5.9 → 0.6.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.
Files changed (43) hide show
  1. package/dist/generated/locale-codes.d.ts +14 -0
  2. package/dist/generated/locale-codes.d.ts.map +1 -0
  3. package/dist/generated/locales/be.d.ts +11 -0
  4. package/dist/generated/locales/be.d.ts.map +1 -0
  5. package/dist/generated/locales/de.d.ts +11 -0
  6. package/dist/generated/locales/de.d.ts.map +1 -0
  7. package/dist/generated/locales/en.d.ts +11 -0
  8. package/dist/generated/locales/en.d.ts.map +1 -0
  9. package/dist/index.d.ts +8 -0
  10. package/dist/index.d.ts.map +1 -0
  11. package/dist/index.js +3 -7
  12. package/dist/locales/be.d.ts +2 -0
  13. package/dist/locales/be.js +2 -1
  14. package/dist/locales/de.d.ts +2 -0
  15. package/dist/locales/de.js +2 -1
  16. package/dist/locales/en.d.ts +2 -0
  17. package/dist/locales/en.js +2 -1
  18. package/dist/pd-contact-us.d.ts +18 -0
  19. package/dist/pd-contact-us.d.ts.map +1 -0
  20. package/dist/pd-contact-us.js +218 -4
  21. package/dist/pd-footer.d.ts +31 -0
  22. package/dist/pd-footer.d.ts.map +1 -0
  23. package/dist/pd-footer.js +165 -4
  24. package/dist/pd-menu.d.ts +67 -0
  25. package/dist/pd-menu.d.ts.map +1 -0
  26. package/dist/pd-menu.js +483 -4
  27. package/dist/stories/01_index.stories.d.ts +5 -0
  28. package/dist/stories/01_index.stories.d.ts.map +1 -0
  29. package/dist/stories/pd-contact-us.stories.d.ts +6 -0
  30. package/dist/stories/pd-contact-us.stories.d.ts.map +1 -0
  31. package/dist/stories/pd-footer.stories.d.ts +8 -0
  32. package/dist/stories/pd-footer.stories.d.ts.map +1 -0
  33. package/dist/stories/pd-menu.stories.d.ts +20 -0
  34. package/dist/stories/pd-menu.stories.d.ts.map +1 -0
  35. package/dist/types.d.ts +25 -0
  36. package/dist/types.d.ts.map +1 -0
  37. package/package.json +31 -48
  38. package/dist/pd-teaser.js +0 -8
  39. package/dist/src/PdContactUs.js +0 -204
  40. package/dist/src/PdFooter.js +0 -140
  41. package/dist/src/PdMenu.js +0 -449
  42. package/dist/src/PdTeaser.js +0 -247
  43. package/dist/src/PdTeaserContent.js +0 -211
@@ -0,0 +1,14 @@
1
+ /**
2
+ * The locale code that templates in this source code are written in.
3
+ */
4
+ export declare const sourceLocale = "dev";
5
+ /**
6
+ * The other locale codes that this application is localized into. Sorted
7
+ * lexicographically.
8
+ */
9
+ export declare const targetLocales: readonly ["be", "de", "en"];
10
+ /**
11
+ * All valid project locale codes. Sorted lexicographically.
12
+ */
13
+ export declare const allLocales: readonly ["be", "de", "dev", "en"];
14
+ //# sourceMappingURL=locale-codes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale-codes.d.ts","sourceRoot":"","sources":["../../src/generated/locale-codes.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,eAAO,MAAM,YAAY,QAAQ,CAAC;AAElC;;;GAGG;AACH,eAAO,MAAM,aAAa,6BAA8B,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,UAAU,oCAAqC,CAAC"}
@@ -0,0 +1,11 @@
1
+ export declare const templates: {
2
+ "pd.contactus.address.email": string;
3
+ "pd.contactus.address.message": string;
4
+ "pd.contactus.address.name": string;
5
+ "pd.contactus.address.phone": string;
6
+ "pd.contactus.address.send": string;
7
+ "pd.contactus.address.title": string;
8
+ "pd.contactus.title": string;
9
+ "pd.menu.label": string;
10
+ };
11
+ //# sourceMappingURL=be.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"be.d.ts","sourceRoot":"","sources":["../../../src/generated/locales/be.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,SAAS;;;;;;;;;CASrB,CAAC"}
@@ -0,0 +1,11 @@
1
+ export declare const templates: {
2
+ "pd.contactus.title": string;
3
+ "pd.contactus.address.title": string;
4
+ "pd.contactus.address.name": string;
5
+ "pd.contactus.address.email": string;
6
+ "pd.contactus.address.phone": string;
7
+ "pd.contactus.address.message": string;
8
+ "pd.contactus.address.send": string;
9
+ "pd.menu.label": string;
10
+ };
11
+ //# sourceMappingURL=de.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"de.d.ts","sourceRoot":"","sources":["../../../src/generated/locales/de.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,SAAS;;;;;;;;;CASrB,CAAC"}
@@ -0,0 +1,11 @@
1
+ export declare const templates: {
2
+ "pd.contactus.address.email": string;
3
+ "pd.contactus.address.message": string;
4
+ "pd.contactus.address.name": string;
5
+ "pd.contactus.address.phone": string;
6
+ "pd.contactus.address.send": string;
7
+ "pd.contactus.address.title": string;
8
+ "pd.contactus.title": string;
9
+ "pd.menu.label": string;
10
+ };
11
+ //# sourceMappingURL=en.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"en.d.ts","sourceRoot":"","sources":["../../../src/generated/locales/en.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,SAAS;;;;;;;;;CASrB,CAAC"}
@@ -0,0 +1,8 @@
1
+ export { PdContactUs } from './pd-contact-us.js';
2
+ export { PdFooter } from './pd-footer.js';
3
+ export { PdMenu } from './pd-menu.js';
4
+ export type { PdFooterLink, PdFooterMadeBy, PdMenuItem } from './types.js';
5
+ export { templates as beTemplates } from './generated/locales/be.js';
6
+ export { templates as deTemplates } from './generated/locales/de.js';
7
+ export { templates as enTemplates } from './generated/locales/en.js';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAEtC,YAAY,EAAE,YAAY,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE3E,OAAO,EAAE,SAAS,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACrE,OAAO,EAAE,SAAS,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACrE,OAAO,EAAE,SAAS,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC"}
package/dist/index.js CHANGED
@@ -1,8 +1,6 @@
1
- import { PdContactUs } from "./src/PdContactUs.js";
2
- import { PdFooter } from "./src/PdFooter.js";
3
- import { PdMenu } from "./src/PdMenu.js";
4
- import { PdTeaser } from "./src/PdTeaser.js";
5
- import { PdTeaserContent } from "./src/PdTeaserContent.js";
1
+ import { PdContactUs } from "./pd-contact-us.js";
2
+ import { PdFooter } from "./pd-footer.js";
3
+ import { PdMenu } from "./pd-menu.js";
6
4
  import { templates } from "./locales/be.js";
7
5
  import { templates as templates2 } from "./locales/de.js";
8
6
  import { templates as templates3 } from "./locales/en.js";
@@ -10,8 +8,6 @@ export {
10
8
  PdContactUs,
11
9
  PdFooter,
12
10
  PdMenu,
13
- PdTeaser,
14
- PdTeaserContent,
15
11
  templates as beTemplates,
16
12
  templates2 as deTemplates,
17
13
  templates3 as enTemplates
@@ -0,0 +1,2 @@
1
+ export * from '../generated/locales/be'
2
+ export {}
@@ -5,7 +5,8 @@ const templates = {
5
5
  "pd.contactus.address.phone": `Telefoon`,
6
6
  "pd.contactus.address.send": `Verzenden`,
7
7
  "pd.contactus.address.title": `Adres`,
8
- "pd.contactus.title": `Contact`
8
+ "pd.contactus.title": `Contact`,
9
+ "pd.menu.label": `Menü`
9
10
  };
10
11
  export {
11
12
  templates
@@ -0,0 +1,2 @@
1
+ export * from '../generated/locales/de'
2
+ export {}
@@ -5,7 +5,8 @@ const templates = {
5
5
  "pd.contactus.address.email": `Email`,
6
6
  "pd.contactus.address.phone": `Telefon`,
7
7
  "pd.contactus.address.message": `Nachricht`,
8
- "pd.contactus.address.send": `Absenden`
8
+ "pd.contactus.address.send": `Absenden`,
9
+ "pd.menu.label": `Menü`
9
10
  };
10
11
  export {
11
12
  templates
@@ -0,0 +1,2 @@
1
+ export * from '../generated/locales/en'
2
+ export {}
@@ -5,7 +5,8 @@ const templates = {
5
5
  "pd.contactus.address.phone": `Phone`,
6
6
  "pd.contactus.address.send": `Send`,
7
7
  "pd.contactus.address.title": `Address`,
8
- "pd.contactus.title": `Contact`
8
+ "pd.contactus.title": `Contact`,
9
+ "pd.menu.label": `Menü`
9
10
  };
10
11
  export {
11
12
  templates
@@ -0,0 +1,18 @@
1
+ import { LitElement, CSSResultGroup } from 'lit';
2
+ import { PdContactData } from '@progressive-development/pd-contact';
3
+ /**
4
+ * Contact form component with company address and message form.
5
+ *
6
+ * @event send-contact-request - Fired when the contact form is valid and submitted.
7
+ */
8
+ export declare class PdContactUs extends LitElement {
9
+ /**
10
+ * Contact data displayed in the address section.
11
+ */
12
+ contact: PdContactData;
13
+ static styles: CSSResultGroup;
14
+ render(): import('lit-html').TemplateResult<1>;
15
+ clear(): void;
16
+ private _sendMail;
17
+ }
18
+ //# sourceMappingURL=pd-contact-us.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pd-contact-us.d.ts","sourceRoot":"","sources":["../src/pd-contact-us.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAa,cAAc,EAAE,MAAM,KAAK,CAAC;AAI5D,OAAO,6CAA6C,CAAC;AACrD,OAAO,qDAAqD,CAAC;AAC7D,OAAO,+CAA+C,CAAC;AACvD,OAAO,4CAA4C,CAAC;AACpD,OAAO,iDAAiD,CAAC;AACzD,OAAO,gDAAgD,CAAC;AAMxD,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE;;;;GAIG;AACH,qBAEa,WAAY,SAAQ,UAAU;IACzC;;OAEG;IAEH,OAAO,EAAE,aAAa,CAAM;IAE5B,OAAgB,MAAM,EAAE,cAAc,CAsEpC;IAEF,MAAM;IAwFN,KAAK,IAAI,IAAI;IAOb,OAAO,CAAC,SAAS;CA0BlB"}
@@ -1,4 +1,218 @@
1
- import { PdContactUs } from "./src/PdContactUs.js";
2
- if (!customElements.get("pd-contact-us")) {
3
- window.customElements.define("pd-contact-us", PdContactUs);
4
- }
1
+ import { css, LitElement, html } from "lit";
2
+ import { localized, msg } from "@lit/localize";
3
+ import { property, customElement } from "lit/decorators.js";
4
+ import "@progressive-development/pd-forms/pd-button";
5
+ import "@progressive-development/pd-forms/pd-form-container";
6
+ import "@progressive-development/pd-forms/pd-form-row";
7
+ import "@progressive-development/pd-forms/pd-input";
8
+ import "@progressive-development/pd-forms/pd-input-area";
9
+ import "@progressive-development/pd-contact/pd-contact";
10
+ import { PdColorStyles, PdFontStyles } from "@progressive-development/pd-shared-styles";
11
+ var __defProp = Object.defineProperty;
12
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
13
+ var __decorateClass = (decorators, target, key, kind) => {
14
+ var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
15
+ for (var i = decorators.length - 1, decorator; i >= 0; i--)
16
+ if (decorator = decorators[i])
17
+ result = (kind ? decorator(target, key, result) : decorator(result)) || result;
18
+ if (kind && result) __defProp(target, key, result);
19
+ return result;
20
+ };
21
+ let PdContactUs = class extends LitElement {
22
+ constructor() {
23
+ super(...arguments);
24
+ this.contact = {};
25
+ }
26
+ render() {
27
+ return html`
28
+ <div class="content-block">
29
+ <h2>${msg("Kontakt", { id: "pd.contactus.title" })}</h2>
30
+ <div class="contact-block">
31
+ <div class="left-content">
32
+ <pd-contact
33
+ class="company-contact"
34
+ .contact="${this.contact}"
35
+ addressTitle="${msg("Adresse", {
36
+ id: "pd.contactus.address.title"
37
+ })}"
38
+ summary
39
+ ></pd-contact>
40
+ </div>
41
+
42
+ <div class="right-content">
43
+ <pd-form-container id="contactFormId">
44
+ <pd-form-row>
45
+ <pd-input
46
+ id="nameInputId"
47
+ class="quarter3"
48
+ placeHolder="${msg("Name", {
49
+ id: "pd.contactus.address.name"
50
+ })}"
51
+ valueName="name"
52
+ autoCompleteName="full-name"
53
+ required
54
+ ></pd-input>
55
+ </pd-form-row>
56
+
57
+ <pd-form-row>
58
+ <pd-input
59
+ id="mailInputId"
60
+ class="quarter3"
61
+ placeHolder="${msg("Email", {
62
+ id: "pd.contactus.address.email"
63
+ })}"
64
+ valueName="mail"
65
+ autoCompleteName="email"
66
+ name="email"
67
+ field-type="mail"
68
+ required
69
+ ></pd-input>
70
+ </pd-form-row>
71
+
72
+ <pd-form-row>
73
+ <pd-input
74
+ id="phoneInputId"
75
+ class="quarter3"
76
+ placeHolder="${msg("Telefon", {
77
+ id: "pd.contactus.address.phone"
78
+ })}"
79
+ valueName="phone"
80
+ field-type="phone"
81
+ autoCompleteName="tel"
82
+ required
83
+ ></pd-input>
84
+ </pd-form-row>
85
+
86
+ <pd-form-row>
87
+ <pd-input-area
88
+ id="msgInputId"
89
+ class="quarter3-area"
90
+ placeHolder="${msg("Nachricht", {
91
+ id: "pd.contactus.address.message"
92
+ })}"
93
+ rows="15"
94
+ required
95
+ valueName="msg"
96
+ ></pd-input-area>
97
+ </pd-form-row>
98
+
99
+ <pd-form-row>
100
+ <pd-button
101
+ class="quarter3"
102
+ text="${msg("Absenden", { id: "pd.contactus.address.send" })}"
103
+ @click="${this._sendMail}"
104
+ primary
105
+ ></pd-button>
106
+ </pd-form-row>
107
+ </pd-form-container>
108
+ </div>
109
+ </div>
110
+ </div>
111
+ `;
112
+ }
113
+ clear() {
114
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
115
+ (_c = (_b = (_a = this.shadowRoot) == null ? void 0 : _a.getElementById("nameInputId")) == null ? void 0 : _b["clear"]) == null ? void 0 : _c.call(_b);
116
+ (_f = (_e = (_d = this.shadowRoot) == null ? void 0 : _d.getElementById("mailInputId")) == null ? void 0 : _e["clear"]) == null ? void 0 : _f.call(_e);
117
+ (_i = (_h = (_g = this.shadowRoot) == null ? void 0 : _g.getElementById("phoneInputId")) == null ? void 0 : _h["clear"]) == null ? void 0 : _i.call(_h);
118
+ (_l = (_k = (_j = this.shadowRoot) == null ? void 0 : _j.getElementById("msgInputId")) == null ? void 0 : _k["clear"]) == null ? void 0 : _l.call(_k);
119
+ }
120
+ _sendMail() {
121
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i;
122
+ const detail = { errorMap: /* @__PURE__ */ new Map() };
123
+ const form = (_a = this.shadowRoot) == null ? void 0 : _a.getElementById("contactFormId");
124
+ form == null ? void 0 : form.dispatchEvent(new CustomEvent("validate-form", { detail }));
125
+ if (detail.errorMap.size === 0) {
126
+ const name = (_c = (_b = this.shadowRoot) == null ? void 0 : _b.getElementById("nameInputId")) == null ? void 0 : _c.value;
127
+ const email = (_e = (_d = this.shadowRoot) == null ? void 0 : _d.getElementById("mailInputId")) == null ? void 0 : _e.value;
128
+ const phone = (_g = (_f = this.shadowRoot) == null ? void 0 : _f.getElementById("phoneInputId")) == null ? void 0 : _g.value;
129
+ const msg1 = (_i = (_h = this.shadowRoot) == null ? void 0 : _h.getElementById("msgInputId")) == null ? void 0 : _i.value;
130
+ this.dispatchEvent(
131
+ new CustomEvent("send-contact-request", {
132
+ detail: { msgObj: { name, email, phone, msg1 } }
133
+ })
134
+ );
135
+ }
136
+ }
137
+ };
138
+ PdContactUs.styles = [
139
+ PdColorStyles,
140
+ PdFontStyles,
141
+ css`
142
+ :host {
143
+ display: flex;
144
+ flex-flow: row;
145
+ background-color: var(--pd-contactus-bg-col, var(--pd-default-col));
146
+ background-image: var(--pd-contactus-bg-image);
147
+ background-repeat: no-repeat;
148
+ min-height: 500px;
149
+ width: 100%;
150
+ }
151
+
152
+ h2 {
153
+ font-family: var(--pd-default-font-title-family);
154
+ font-style: normal;
155
+ color: var(--pd-contactus-font-col, var(--pd-default-bg-col));
156
+ margin-top: 1.4em;
157
+ margin-bottom: 2.5rem;
158
+ font-size: var(--pd-contactus-font-h2-size, 2.5rem);
159
+ }
160
+
161
+ .content-block {
162
+ overflow: hidden;
163
+ display: flex;
164
+ flex-direction: column;
165
+ align-items: flex-start;
166
+ justify-content: flex-start;
167
+ flex-grow: 1;
168
+ max-width: 1170px;
169
+ margin: 0 auto;
170
+ padding-left: 30px;
171
+ }
172
+
173
+ .contact-block {
174
+ display: flex;
175
+ flex-wrap: wrap;
176
+ padding-bottom: 50px;
177
+ }
178
+
179
+ .left-content {
180
+ width: 35%;
181
+ min-width: 230px;
182
+ }
183
+
184
+ .right-content {
185
+ width: 65%;
186
+ }
187
+
188
+ .company-contact {
189
+ --app-font-content-col: var(
190
+ --pd-contactus-font-col,
191
+ var(--pd-default-bg-col)
192
+ );
193
+ --app-font-title-col: var(
194
+ --pd-contactus-font-col,
195
+ var(--pd-default-bg-col)
196
+ );
197
+ }
198
+
199
+ @media (max-width: 440px) {
200
+ .item {
201
+ display: none;
202
+ }
203
+ ul {
204
+ justify-content: flex-start;
205
+ }
206
+ }
207
+ `
208
+ ];
209
+ __decorateClass([
210
+ property({ type: Object })
211
+ ], PdContactUs.prototype, "contact", 2);
212
+ PdContactUs = __decorateClass([
213
+ customElement("pd-contact-us"),
214
+ localized()
215
+ ], PdContactUs);
216
+ export {
217
+ PdContactUs
218
+ };
@@ -0,0 +1,31 @@
1
+ import { LitElement, CSSResultGroup } from 'lit';
2
+ import { PdFooterLink, PdFooterMadeBy } from './types';
3
+ /**
4
+ * Footer-Komponente mit konfigurierbaren Links, Version und Copyright.
5
+ *
6
+ * @fires footer-link - Wird ausgelöst, wenn auf einen Footer-Link geklickt wird.
7
+ * @slot - Standard-Slot nicht verwendet.
8
+ */
9
+ export declare class PdFooter extends LitElement {
10
+ /**
11
+ * Optional: Copyright-Zeile, z.B. "2024 PD Progressive Development UG".
12
+ */
13
+ copyright: string;
14
+ /**
15
+ * Optionale Versionsangabe, z.B. "v1.2.3".
16
+ */
17
+ version: string;
18
+ /**
19
+ * Optionaler Verweis auf den Entwickler oder die Agentur.
20
+ */
21
+ madeBy?: PdFooterMadeBy;
22
+ /**
23
+ * Liste von Footer-Links.
24
+ */
25
+ footerLinks: PdFooterLink[];
26
+ static styles: CSSResultGroup;
27
+ render(): import('lit-html').TemplateResult<1>;
28
+ private _clickMadeBy;
29
+ private _footerLinkClicked;
30
+ }
31
+ //# sourceMappingURL=pd-footer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pd-footer.d.ts","sourceRoot":"","sources":["../src/pd-footer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAsB,cAAc,EAAE,MAAM,KAAK,CAAC;AAMrE,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAEvD;;;;;GAKG;AACH,qBACa,QAAS,SAAQ,UAAU;IACtC;;OAEG;IAEH,SAAS,SAAM;IAEf;;OAEG;IAEH,OAAO,SAAM;IAEb;;OAEG;IAEH,MAAM,CAAC,EAAE,cAAc,CAAC;IAExB;;OAEG;IAEH,WAAW,EAAE,YAAY,EAAE,CAAM;IAEjC,OAAgB,MAAM,EAAE,cAAc,CA2EpC;IAEO,MAAM;IAmCf,OAAO,CAAC,YAAY;IAQpB,OAAO,CAAC,kBAAkB;CAe3B"}
package/dist/pd-footer.js CHANGED
@@ -1,4 +1,165 @@
1
- import { PdFooter } from "./src/PdFooter.js";
2
- if (!customElements.get("pd-footer")) {
3
- window.customElements.define("pd-footer", PdFooter);
4
- }
1
+ import { css, LitElement, nothing, html } from "lit";
2
+ import { property, customElement } from "lit/decorators.js";
3
+ import { PdColorStyles, PdFontStyles } from "@progressive-development/pd-shared-styles";
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __decorateClass = (decorators, target, key, kind) => {
7
+ var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
8
+ for (var i = decorators.length - 1, decorator; i >= 0; i--)
9
+ if (decorator = decorators[i])
10
+ result = (kind ? decorator(target, key, result) : decorator(result)) || result;
11
+ if (kind && result) __defProp(target, key, result);
12
+ return result;
13
+ };
14
+ let PdFooter = class extends LitElement {
15
+ constructor() {
16
+ super(...arguments);
17
+ this.copyright = "";
18
+ this.version = "";
19
+ this.footerLinks = [];
20
+ }
21
+ render() {
22
+ return html`
23
+ <div class="footer-links">
24
+ <ul>
25
+ ${this.footerLinks.map(
26
+ (link) => html`
27
+ <li>
28
+ <a @click=${this._footerLinkClicked} data-link=${link.key}
29
+ >${link.name}</a
30
+ >
31
+ </li>
32
+ `
33
+ )}
34
+ </ul>
35
+ </div>
36
+
37
+ <div class="bottom-line">
38
+ <div>
39
+ ${this.copyright ? html`<span class="copyright">© ${this.copyright}, </span>` : nothing}
40
+ ${this.version ? html`<span class="version">${this.version}</span>` : nothing}
41
+ </div>
42
+
43
+ ${this.madeBy ? html`<span class="madeBy" @click=${this._clickMadeBy}
44
+ >${this.madeBy.txt}</span
45
+ >` : nothing}
46
+ </div>
47
+ `;
48
+ }
49
+ _clickMadeBy() {
50
+ var _a, _b;
51
+ if ((_a = this.madeBy) == null ? void 0 : _a.email) {
52
+ window.location.href = `mailto:${this.madeBy.email}`;
53
+ } else if ((_b = this.madeBy) == null ? void 0 : _b.link) {
54
+ window.open(this.madeBy.link, "_blank");
55
+ }
56
+ }
57
+ _footerLinkClicked(e) {
58
+ const target = e.currentTarget;
59
+ const linkKey = target.dataset.link;
60
+ const linkObj = this.footerLinks.find((fl) => fl.key === linkKey);
61
+ if (linkObj) {
62
+ this.dispatchEvent(
63
+ new CustomEvent("footer-link", {
64
+ detail: { linkObj },
65
+ bubbles: true,
66
+ composed: true
67
+ })
68
+ );
69
+ }
70
+ }
71
+ };
72
+ PdFooter.styles = [
73
+ PdColorStyles,
74
+ PdFontStyles,
75
+ css`
76
+ :host {
77
+ display: flex;
78
+ flex-flow: column;
79
+ justify-content: end;
80
+ background-color: var(--pd-footer-bg-col, var(--pd-default-col));
81
+ width: 100%;
82
+ white-space: nowrap;
83
+ }
84
+
85
+ .footer-links {
86
+ display: flex;
87
+ align-items: center;
88
+ justify-content: right;
89
+ height: 100%;
90
+ color: var(--pd-footer-font-col, var(--pd-default-bg-col));
91
+ font-family: var(
92
+ --pd-footer-font-family,
93
+ var(--pd-default-font-link-family)
94
+ );
95
+ font-size: var(--pd-footer-font-size, 1.1em);
96
+ }
97
+
98
+ .footer-links ul {
99
+ display: flex;
100
+ flex-wrap: wrap;
101
+ list-style: none;
102
+ gap: 2em;
103
+ margin: 0;
104
+ padding: 2em 2.5em;
105
+ }
106
+
107
+ .footer-links li {
108
+ cursor: pointer;
109
+ }
110
+
111
+ .footer-links li:hover {
112
+ color: var(--pd-default-hover-col);
113
+ }
114
+
115
+ .bottom-line {
116
+ background-color: var(
117
+ --pd-footer-bottom-col,
118
+ var(--pd-default-light-col)
119
+ );
120
+ font-size: var(--pd-footer-bottom-font-size, 0.9em);
121
+ color: var(--pd-footer-bottom-font-col, var(--pd-default-dark-col));
122
+ padding: 0.5em;
123
+ display: flex;
124
+ gap: 1em;
125
+ flex-wrap: wrap;
126
+ justify-content: space-between;
127
+ align-items: center;
128
+ }
129
+
130
+ .copyright {
131
+ font-weight: bold;
132
+ }
133
+
134
+ .version {
135
+ font-weight: normal;
136
+ }
137
+
138
+ .madeBy {
139
+ cursor: pointer;
140
+ font-style: italic;
141
+ }
142
+
143
+ .madeBy:hover {
144
+ color: var(--pd-default-col);
145
+ }
146
+ `
147
+ ];
148
+ __decorateClass([
149
+ property({ type: String })
150
+ ], PdFooter.prototype, "copyright", 2);
151
+ __decorateClass([
152
+ property({ type: String })
153
+ ], PdFooter.prototype, "version", 2);
154
+ __decorateClass([
155
+ property({ type: Object })
156
+ ], PdFooter.prototype, "madeBy", 2);
157
+ __decorateClass([
158
+ property({ type: Array })
159
+ ], PdFooter.prototype, "footerLinks", 2);
160
+ PdFooter = __decorateClass([
161
+ customElement("pd-footer")
162
+ ], PdFooter);
163
+ export {
164
+ PdFooter
165
+ };
@@ -0,0 +1,67 @@
1
+ import { LitElement, CSSResultGroup } from 'lit';
2
+ import { PdMenuItem } from './types.js';
3
+ /**
4
+ * Menü-Komponente zur Navigation in der Anwendung.
5
+ *
6
+ * @fires route-event – Wird ausgelöst, wenn ein Menüpunkt mit Route geklickt wird
7
+ * @fires locale-change – Wird ausgelöst, wenn die Sprache gewechselt wird
8
+ *
9
+ * @slot slotLogo – Slot für das App-Logo
10
+ */
11
+ export declare class PdMenu extends LitElement {
12
+ /**
13
+ * Aktuelle aktive Route (zur Hervorhebung)
14
+ */
15
+ activeRoute: string;
16
+ /**
17
+ * Aktuell ausgewählte Sprache
18
+ */
19
+ selectedLocale: string;
20
+ /**
21
+ * Liste verfügbarer Sprachen
22
+ */
23
+ locales: string[];
24
+ /**
25
+ * Hauptmenüeinträge
26
+ */
27
+ menuItems: PdMenuItem[];
28
+ /**
29
+ * Zusätzliche Einträge in der oberen Menüzeile
30
+ */
31
+ topMenuItems: PdMenuItem[];
32
+ /**
33
+ * Flag, ob Burger-Menü deaktiviert ist
34
+ */
35
+ noBurgerMenu: boolean;
36
+ /**
37
+ * Größe des Headers (für Scroll-Berechnung)
38
+ */
39
+ headerSize: number;
40
+ /**
41
+ * Index des aktiven Inhaltsbereichs (bei Scroll)
42
+ */
43
+ private _activeSecIndex;
44
+ /**
45
+ * Burger-Menü aktiv?
46
+ */
47
+ private _activeBurgerMenu;
48
+ /**
49
+ * Sprachmenü aktiv?
50
+ */
51
+ private _activeLocaleMenu;
52
+ /**
53
+ * Zeige mobile Ansicht?
54
+ */
55
+ private _smallScreen;
56
+ static styles: CSSResultGroup;
57
+ protected firstUpdated(): void;
58
+ render(): import('lit-html').TemplateResult<1>;
59
+ private _renderItems;
60
+ private _toggleBurgerMenu;
61
+ private _toggleLocaleSelection;
62
+ private _localeClicked;
63
+ private _menuItemClicked;
64
+ private _logoClicked;
65
+ private static _scrollToTop;
66
+ }
67
+ //# sourceMappingURL=pd-menu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pd-menu.d.ts","sourceRoot":"","sources":["../src/pd-menu.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAa,cAAc,EAAE,MAAM,KAAK,CAAC;AAW5D,OAAO,0CAA0C,CAAC;AAElD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C;;;;;;;GAOG;AACH,qBACa,MAAO,SAAQ,UAAU;IACpC;;OAEG;IAEH,WAAW,SAAM;IAEjB;;OAEG;IAEH,cAAc,SAAM;IAEpB;;OAEG;IAEH,OAAO,EAAE,MAAM,EAAE,CAAM;IAEvB;;OAEG;IAEH,SAAS,EAAE,UAAU,EAAE,CAAM;IAE7B;;OAEG;IAEH,YAAY,EAAE,UAAU,EAAE,CAAM;IAEhC;;OAEG;IAEH,YAAY,UAAS;IAErB;;OAEG;IAEH,UAAU,SAAK;IAEf;;OAEG;IAEH,OAAO,CAAC,eAAe,CAAK;IAE5B;;OAEG;IAEH,OAAO,CAAC,iBAAiB,CAAS;IAElC;;OAEG;IAEH,OAAO,CAAC,iBAAiB,CAAS;IAElC;;OAEG;IAEH,OAAO,CAAC,YAAY,CAAS;IAE7B,OAAgB,MAAM,EAAE,cAAc,CA0PpC;IAEF,SAAS,CAAC,YAAY;IAmCtB,MAAM;IAqEN,OAAO,CAAC,YAAY;IAiCpB,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,sBAAsB;IAI9B,OAAO,CAAC,cAAc;IAKtB,OAAO,CAAC,gBAAgB;IA8BxB,OAAO,CAAC,YAAY;IAWpB,OAAO,CAAC,MAAM,CAAC,YAAY;CAG5B"}