@molecule/app-settings-panel-angular 0.0.0-stage → 0.0.1-stage

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 (63) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +1992 -2
  3. package/dist/account-section.component.d.ts +123 -0
  4. package/dist/account-section.component.d.ts.map +1 -0
  5. package/dist/account-section.component.js +350 -0
  6. package/dist/account-section.component.js.map +1 -0
  7. package/dist/appearance-section.component.d.ts +52 -0
  8. package/dist/appearance-section.component.d.ts.map +1 -0
  9. package/dist/appearance-section.component.js +128 -0
  10. package/dist/appearance-section.component.js.map +1 -0
  11. package/dist/auth-section.component.d.ts +125 -0
  12. package/dist/auth-section.component.d.ts.map +1 -0
  13. package/dist/auth-section.component.js +667 -0
  14. package/dist/auth-section.component.js.map +1 -0
  15. package/dist/billing-section.component.d.ts +52 -0
  16. package/dist/billing-section.component.d.ts.map +1 -0
  17. package/dist/billing-section.component.js +137 -0
  18. package/dist/billing-section.component.js.map +1 -0
  19. package/dist/context.d.ts +46 -0
  20. package/dist/context.d.ts.map +1 -0
  21. package/dist/context.js +73 -0
  22. package/dist/context.js.map +1 -0
  23. package/dist/controlled-switch.d.ts +38 -0
  24. package/dist/controlled-switch.d.ts.map +1 -0
  25. package/dist/controlled-switch.js +56 -0
  26. package/dist/controlled-switch.js.map +1 -0
  27. package/dist/devices-section.component.d.ts +88 -0
  28. package/dist/devices-section.component.d.ts.map +1 -0
  29. package/dist/devices-section.component.js +374 -0
  30. package/dist/devices-section.component.js.map +1 -0
  31. package/dist/index.d.ts +107 -0
  32. package/dist/index.d.ts.map +1 -0
  33. package/dist/index.js +107 -0
  34. package/dist/index.js.map +1 -0
  35. package/dist/log-out-delete-section.component.d.ts +50 -0
  36. package/dist/log-out-delete-section.component.d.ts.map +1 -0
  37. package/dist/log-out-delete-section.component.js +249 -0
  38. package/dist/log-out-delete-section.component.js.map +1 -0
  39. package/dist/notifications-section.component.d.ts +78 -0
  40. package/dist/notifications-section.component.d.ts.map +1 -0
  41. package/dist/notifications-section.component.js +256 -0
  42. package/dist/notifications-section.component.js.map +1 -0
  43. package/dist/push-toggle.d.ts +12 -0
  44. package/dist/push-toggle.d.ts.map +1 -0
  45. package/dist/push-toggle.js +11 -0
  46. package/dist/push-toggle.js.map +1 -0
  47. package/dist/settings-container.component.d.ts +33 -0
  48. package/dist/settings-container.component.d.ts.map +1 -0
  49. package/dist/settings-container.component.js +64 -0
  50. package/dist/settings-container.component.js.map +1 -0
  51. package/dist/this-device-section.component.d.ts +40 -0
  52. package/dist/this-device-section.component.d.ts.map +1 -0
  53. package/dist/this-device-section.component.js +149 -0
  54. package/dist/this-device-section.component.js.map +1 -0
  55. package/dist/tiers-upgrade-section.component.d.ts +89 -0
  56. package/dist/tiers-upgrade-section.component.d.ts.map +1 -0
  57. package/dist/tiers-upgrade-section.component.js +407 -0
  58. package/dist/tiers-upgrade-section.component.js.map +1 -0
  59. package/dist/types.d.ts +46 -0
  60. package/dist/types.d.ts.map +1 -0
  61. package/dist/types.js +8 -0
  62. package/dist/types.js.map +1 -0
  63. package/package.json +78 -4
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth-section.component.js","sourceRoot":"","sources":["../src/auth-section.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAE/E,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAEjG,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AAEvD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAC9C,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;;;;;;;;;;;;;;;;;IA0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} from '@molecule/app-ui';
2
+ import * as i0 from "@angular/core";
3
+ /**
4
+ * BillingSection component.
5
+ *
6
+ * Billing section — current plan + Upgrade button. The host IS the
7
+ * `<section>` React renders.
8
+ *
9
+ * Fetches `/api/billing/status` on mount and uses the returned plan name as a
10
+ * more accurate label than the parent-supplied default. The `plan` input
11
+ * remains a fallback (e.g. for offline rendering or apps that don't expose
12
+ * `/billing/status`).
13
+ *
14
+ * The Upgrade button navigates to `upgradeTo` (default `/settings`). Pass
15
+ * `upgradeTo="/billing"` or `upgradeTo="/pricing"` if your app routes
16
+ * elsewhere. Apps with a multi-tier checkout flow should use
17
+ * `TiersUpgradeSection` instead.
18
+ */
19
+ export declare class BillingSection {
20
+ /** Fallback plan name when `/api/billing/status` is unavailable. */
21
+ plan: string;
22
+ /** Route the Upgrade button navigates to. */
23
+ upgradeTo: string;
24
+ /** Reactive translation, read in the injection context. */
25
+ protected readonly i18n: import("@molecule/app-angular").UseTranslationResult;
26
+ /** The translation function for the template. */
27
+ protected t: (key: string, values?: import("@molecule/app-i18n").InterpolationValues, options?: import("@molecule/app-i18n").TranslateOptions) => string;
28
+ private readonly http;
29
+ /** The binding's router (throws outside one, like react-router's useNavigate). */
30
+ private readonly router;
31
+ /** The plan name loaded from `/api/billing/status`, or null. */
32
+ private readonly livePlan;
33
+ /** The bonded ClassMap (styling tokens resolve at render time). */
34
+ protected readonly cm: UIClassMap;
35
+ /**
36
+ * The displayed plan label (React's `livePlan ?? plan`).
37
+ * @returns The plan name.
38
+ */
39
+ protected planLabel(): string;
40
+ /**
41
+ * Reads the current plan from the bonded entitlements/billing status
42
+ * endpoint on mount (React's mount effect). Fire-and-forget; the
43
+ * input-supplied `plan` is the fallback if the fetch fails. A result that
44
+ * lands after unmount is dropped like React's cancelled one.
45
+ */
46
+ constructor();
47
+ /** Navigates to the upgrade route (React's `navigate(upgradeTo)`). */
48
+ protected upgrade(): void;
49
+ static ɵfac: i0.ɵɵFactoryDeclaration<BillingSection, never>;
50
+ static ɵcmp: i0.ɵɵComponentDeclaration<BillingSection, "section[mol-settings-billing]", never, { "plan": { "alias": "plan"; "required": false; }; "upgradeTo": { "alias": "upgradeTo"; "required": false; }; }, {}, never, never, true, never>;
51
+ }
52
+ //# sourceMappingURL=billing-section.component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"billing-section.component.d.ts","sourceRoot":"","sources":["../src/billing-section.component.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;;AAIlD;;;;;;;;;;;;;;;GAeG;AACH,qBAkBa,cAAc;IACzB,oEAAoE;IACpE,IAAI,SAAS;IACb,6CAA6C;IAC7C,SAAS,SAAc;IAEvB,2DAA2D;IAC3D,SAAS,CAAC,QAAQ,CAAC,IAAI,uDAAmB;IAE1C,iDAAiD;IACjD,SAAS,CAAC,CAAC,8IAAc;IAEzB,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAkB;IAEvC,kFAAkF;IAClF,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAc;IAErC,gEAAgE;IAChE,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAA8B;IAEvD,mEAAmE;IACnE,SAAS,CAAC,QAAQ,CAAC,EAAE,EAAE,UAAU,CAAgB;IAEjD;;;OAGG;IACH,SAAS,CAAC,SAAS,IAAI,MAAM;IAI7B;;;;;OAKG;;IAoBH,sEAAsE;IACtE,SAAS,CAAC,OAAO,IAAI,IAAI;yCAzDd,cAAc;2CAAd,cAAc;CA4D1B"}
@@ -0,0 +1,137 @@
1
+ /**
2
+ * BillingSection component (React parity).
3
+ *
4
+ * @module
5
+ */
6
+ import { Component, DestroyRef, inject, signal } from '@angular/core';
7
+ import { useHttpClient, useRouter, useTranslation } from '@molecule/app-angular';
8
+ import { getClassMap } from '@molecule/app-ui';
9
+ import { Button, Flex } from '@molecule/app-ui-angular';
10
+ import * as i0 from "@angular/core";
11
+ const _c0 = () => ({ defaultValue: "Billing" });
12
+ const _c1 = () => ({ defaultValue: "Plan: " });
13
+ const _c2 = () => ({ defaultValue: "Upgrade" });
14
+ /**
15
+ * BillingSection component.
16
+ *
17
+ * Billing section — current plan + Upgrade button. The host IS the
18
+ * `<section>` React renders.
19
+ *
20
+ * Fetches `/api/billing/status` on mount and uses the returned plan name as a
21
+ * more accurate label than the parent-supplied default. The `plan` input
22
+ * remains a fallback (e.g. for offline rendering or apps that don't expose
23
+ * `/billing/status`).
24
+ *
25
+ * The Upgrade button navigates to `upgradeTo` (default `/settings`). Pass
26
+ * `upgradeTo="/billing"` or `upgradeTo="/pricing"` if your app routes
27
+ * elsewhere. Apps with a multi-tier checkout flow should use
28
+ * `TiersUpgradeSection` instead.
29
+ */
30
+ export class BillingSection {
31
+ /** Fallback plan name when `/api/billing/status` is unavailable. */
32
+ plan = 'Free';
33
+ /** Route the Upgrade button navigates to. */
34
+ upgradeTo = '/settings';
35
+ /** Reactive translation, read in the injection context. */
36
+ i18n = useTranslation();
37
+ /** The translation function for the template. */
38
+ t = this.i18n.t;
39
+ http = useHttpClient();
40
+ /** The binding's router (throws outside one, like react-router's useNavigate). */
41
+ router = useRouter();
42
+ /** The plan name loaded from `/api/billing/status`, or null. */
43
+ livePlan = signal(null, /* @ts-ignore */
44
+ ...(ngDevMode ? [{ debugName: "livePlan" }] : /* istanbul ignore next */ []));
45
+ /** The bonded ClassMap (styling tokens resolve at render time). */
46
+ cm = getClassMap();
47
+ /**
48
+ * The displayed plan label (React's `livePlan ?? plan`).
49
+ * @returns The plan name.
50
+ */
51
+ planLabel() {
52
+ return this.livePlan() ?? this.plan;
53
+ }
54
+ /**
55
+ * Reads the current plan from the bonded entitlements/billing status
56
+ * endpoint on mount (React's mount effect). Fire-and-forget; the
57
+ * input-supplied `plan` is the fallback if the fetch fails. A result that
58
+ * lands after unmount is dropped like React's cancelled one.
59
+ */
60
+ constructor() {
61
+ let cancelled = false;
62
+ inject(DestroyRef).onDestroy(() => {
63
+ cancelled = true;
64
+ });
65
+ void this.http
66
+ .get('/api/billing/status')
67
+ .then((res) => {
68
+ if (cancelled)
69
+ return;
70
+ const body = res.data ?? res;
71
+ const name = body?.name;
72
+ if (typeof name === 'string' && name)
73
+ this.livePlan.set(name);
74
+ })
75
+ .catch((_error) => {
76
+ // fallback to the input-supplied plan label
77
+ });
78
+ }
79
+ /** Navigates to the upgrade route (React's `navigate(upgradeTo)`). */
80
+ upgrade() {
81
+ this.router.navigate(this.upgradeTo);
82
+ }
83
+ static ɵfac = function BillingSection_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || BillingSection)(); };
84
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: BillingSection, selectors: [["section", "mol-settings-billing", ""]], inputs: { plan: "plan", upgradeTo: "upgradeTo" }, decls: 9, vars: 15, consts: [["mol-flex", "", 3, "align", "justify"], ["mol-button", "", 3, "click", "variant", "size"]], template: function BillingSection_Template(rf, ctx) { if (rf & 1) {
85
+ i0.ɵɵelementStart(0, "h3");
86
+ i0.ɵɵtext(1);
87
+ i0.ɵɵelementEnd();
88
+ i0.ɵɵelementStart(2, "div", 0)(3, "span");
89
+ i0.ɵɵtext(4);
90
+ i0.ɵɵelementStart(5, "strong");
91
+ i0.ɵɵtext(6);
92
+ i0.ɵɵelementEnd()();
93
+ i0.ɵɵelementStart(7, "button", 1);
94
+ i0.ɵɵlistener("click", function BillingSection_Template_button_click_7_listener() { return ctx.upgrade(); });
95
+ i0.ɵɵtext(8);
96
+ i0.ɵɵelementEnd()();
97
+ } if (rf & 2) {
98
+ i0.ɵɵclassMap(ctx.cm.cn(ctx.cm.sectionHeading, ctx.cm.sp("mb", 3)));
99
+ i0.ɵɵadvance();
100
+ i0.ɵɵtextInterpolate1(" ", ctx.t("settings.billing", undefined, i0.ɵɵpureFunction0(12, _c0)), " ");
101
+ i0.ɵɵadvance();
102
+ i0.ɵɵproperty("align", "center")("justify", "between");
103
+ i0.ɵɵadvance();
104
+ i0.ɵɵclassMap(ctx.cm.textSize("sm"));
105
+ i0.ɵɵadvance();
106
+ i0.ɵɵtextInterpolate(ctx.t("settings.plan", undefined, i0.ɵɵpureFunction0(13, _c1)));
107
+ i0.ɵɵadvance(2);
108
+ i0.ɵɵtextInterpolate(ctx.planLabel());
109
+ i0.ɵɵadvance();
110
+ i0.ɵɵproperty("variant", "outline")("size", "sm");
111
+ i0.ɵɵadvance();
112
+ i0.ɵɵtextInterpolate1(" ", ctx.t("settings.upgrade", undefined, i0.ɵɵpureFunction0(14, _c2)), " ");
113
+ } }, dependencies: [Button, Flex], encapsulation: 2 });
114
+ }
115
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BillingSection, [{
116
+ type: Component,
117
+ args: [{
118
+ selector: 'section[mol-settings-billing]',
119
+ standalone: true,
120
+ imports: [Button, Flex],
121
+ inputs: ['plan', 'upgradeTo'],
122
+ template: `<h3 [class]="cm.cn(cm.sectionHeading, cm.sp('mb', 3))">
123
+ {{ t('settings.billing', undefined, { defaultValue: 'Billing' }) }}
124
+ </h3>
125
+ <div mol-flex [align]="'center'" [justify]="'between'">
126
+ <span [class]="cm.textSize('sm')"
127
+ >{{ t('settings.plan', undefined, { defaultValue: 'Plan: ' })
128
+ }}<strong>{{ planLabel() }}</strong></span
129
+ >
130
+ <button mol-button [variant]="'outline'" [size]="'sm'" (click)="upgrade()">
131
+ {{ t('settings.upgrade', undefined, { defaultValue: 'Upgrade' }) }}
132
+ </button>
133
+ </div>`,
134
+ }]
135
+ }], () => [], null); })();
136
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(BillingSection, { className: "BillingSection", filePath: "billing-section.component.ts", lineNumber: 48 }); })();
137
+ //# sourceMappingURL=billing-section.component.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"billing-section.component.js","sourceRoot":"","sources":["../src/billing-section.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAA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IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI;gBAAE,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;QAC/D,CAAC,CAAC;aACD,KAAK,CAAC,CAAC,MAAM,EAAE,EAAE;YAChB,4CAA4C;QAC9C,CAAC,CAAC,CAAA;IACN,CAAC;IAED,sEAAsE;IAC5D,OAAO;QACf,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC,CAAA;IACtC,CAAC;wGA3DU,cAAc;6DAAd,cAAc;YAbd,0BAAuD;YAC9D,YACF;YAAA,iBAAK;YAEH,AADF,8BAAuD,WAElD;YAAA,YACC;YAAA,8BAAQ;YAAA,YAAiB;YAAS,AAAT,iBAAS,EACrC;YACD,iCAA2E;YAApB,2FAAS,aAAS,IAAC;YACxE,YACF;YACF,AADE,iBAAS,EACL;;YAXO,mEAAkD;YAC7D,cACF;YADE,kGACF;YACc,cAAkB;YAAC,AAAnB,gCAAkB,sBAAsB;YAC9C,cAA2B;YAA3B,oCAA2B;YAC9B,cACC;YADD,oFACC;YAAQ,eAAiB;YAAjB,qCAAiB;YAEV,cAAqB;YAAC,AAAtB,mCAAqB,cAAc;YACpD,cACF;YADE,kGACF;4BAZM,MAAM,EAAE,IAAI;;iFAeX,cAAc;cAlB1B,SAAS;eAAC;gBACT,QAAQ,EAAE,+BAA+B;gBACzC,UAAU,EAAE,IAAI;gBAChB,OAAO,EAAE,CAAC,MAAM,EAAE,IAAI,CAAC;gBACvB,MAAM,EAAE,CAAC,MAAM,EAAE,WAAW,CAAC;gBAC7B,QAAQ,EAAE;;;;;;;;;;;WAWD;aACV;;kFACY,cAAc"}
@@ -0,0 +1,46 @@
1
+ /**
2
+ * The settings-panel container context — Angular's publication of React's
3
+ * `SettingsPanelContext`.
4
+ *
5
+ * React context flows through the rendered tree, including projected
6
+ * children. Angular DI does not: `<ng-content>` nodes keep their declaration
7
+ * site's injector, so a provider on the container is invisible to sections
8
+ * projected inside it. The container therefore registers the context value on
9
+ * its own host ELEMENT (the same DOM-scoped mechanism
10
+ * `@molecule/app-ui-angular` uses for its contexts) and sections look it up by
11
+ * walking their DOM ancestors — the same "nearest enclosing provider in the
12
+ * rendered tree" semantics React has.
13
+ *
14
+ * @module
15
+ */
16
+ import type { SettingsPanelContextValue } from './types.js';
17
+ /**
18
+ * Names the container context `SettingsContainer` publishes and sections
19
+ * consume (React's `SettingsPanelContext` object). Angular's counterpart is
20
+ * the DOM-scoped registration on the container's host element; this constant
21
+ * documents and keys that contract.
22
+ */
23
+ export declare const SettingsPanelContext = "molecule-settings-panel-context";
24
+ /**
25
+ * Registers the container context on `SettingsContainer`'s host element. The
26
+ * value closes over the container instance, so the context always exposes the
27
+ * CURRENT `onClose` prop — React re-renders a new context value object when
28
+ * the prop changes; reading the live field here has the same effect.
29
+ *
30
+ * @param host - The container's host element.
31
+ * @param readOnClose - Reads the container's current `onClose` prop.
32
+ * @returns A function that removes the registration (call on destroy).
33
+ */
34
+ export declare function provideSettingsPanelContext(host: Element, readOnClose: () => (() => void) | undefined): () => void;
35
+ /**
36
+ * Reads the `onClose` handler exposed by the parent `<SettingsContainer>`.
37
+ * Throws if used outside the container so component misuse is loud.
38
+ *
39
+ * The lookup is deferred to the first property read (an event handler, long
40
+ * after Angular has created and attached every element), so a section nested
41
+ * in projected content resolves the container reliably.
42
+ *
43
+ * @returns The container context.
44
+ */
45
+ export declare function useSettingsPanelContext(): SettingsPanelContextValue;
46
+ //# sourceMappingURL=context.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAMH,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,YAAY,CAAA;AAE3D;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,oCAAoC,CAAA;AAErE;;;;;;;;;GASG;AACH,wBAAgB,2BAA2B,CACzC,IAAI,EAAE,OAAO,EACb,WAAW,EAAE,MAAM,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,GAC1C,MAAM,IAAI,CAWZ;AAED;;;;;;;;;GASG;AACH,wBAAgB,uBAAuB,IAAI,yBAAyB,CAgBnE"}
@@ -0,0 +1,73 @@
1
+ /**
2
+ * The settings-panel container context — Angular's publication of React's
3
+ * `SettingsPanelContext`.
4
+ *
5
+ * React context flows through the rendered tree, including projected
6
+ * children. Angular DI does not: `<ng-content>` nodes keep their declaration
7
+ * site's injector, so a provider on the container is invisible to sections
8
+ * projected inside it. The container therefore registers the context value on
9
+ * its own host ELEMENT (the same DOM-scoped mechanism
10
+ * `@molecule/app-ui-angular` uses for its contexts) and sections look it up by
11
+ * walking their DOM ancestors — the same "nearest enclosing provider in the
12
+ * rendered tree" semantics React has.
13
+ *
14
+ * @module
15
+ */
16
+ import { ElementRef, inject } from '@angular/core';
17
+ import { findDomContext, provideDomContext, removeDomContext } from '@molecule/app-ui-angular';
18
+ /**
19
+ * Names the container context `SettingsContainer` publishes and sections
20
+ * consume (React's `SettingsPanelContext` object). Angular's counterpart is
21
+ * the DOM-scoped registration on the container's host element; this constant
22
+ * documents and keys that contract.
23
+ */
24
+ export const SettingsPanelContext = 'molecule-settings-panel-context';
25
+ /**
26
+ * Registers the container context on `SettingsContainer`'s host element. The
27
+ * value closes over the container instance, so the context always exposes the
28
+ * CURRENT `onClose` prop — React re-renders a new context value object when
29
+ * the prop changes; reading the live field here has the same effect.
30
+ *
31
+ * @param host - The container's host element.
32
+ * @param readOnClose - Reads the container's current `onClose` prop.
33
+ * @returns A function that removes the registration (call on destroy).
34
+ */
35
+ export function provideSettingsPanelContext(host, readOnClose) {
36
+ const value = {
37
+ onClose: () => {
38
+ const onClose = readOnClose();
39
+ if (onClose)
40
+ onClose();
41
+ },
42
+ };
43
+ provideDomContext(host, value);
44
+ return () => {
45
+ removeDomContext(host);
46
+ };
47
+ }
48
+ /**
49
+ * Reads the `onClose` handler exposed by the parent `<SettingsContainer>`.
50
+ * Throws if used outside the container so component misuse is loud.
51
+ *
52
+ * The lookup is deferred to the first property read (an event handler, long
53
+ * after Angular has created and attached every element), so a section nested
54
+ * in projected content resolves the container reliably.
55
+ *
56
+ * @returns The container context.
57
+ */
58
+ export function useSettingsPanelContext() {
59
+ const host = inject(ElementRef).nativeElement;
60
+ const resolve = () => {
61
+ const value = findDomContext(host);
62
+ if (!value) {
63
+ throw new Error('Settings panel section components must be rendered inside <SettingsContainer>.');
64
+ }
65
+ return value;
66
+ };
67
+ return {
68
+ get onClose() {
69
+ return resolve().onClose;
70
+ },
71
+ };
72
+ }
73
+ //# sourceMappingURL=context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.js","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAElD,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAA;AAI9F;;;;;GAKG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,iCAAiC,CAAA;AAErE;;;;;;;;;GASG;AACH,MAAM,UAAU,2BAA2B,CACzC,IAAa,EACb,WAA2C;IAE3C,MAAM,KAAK,GAA8B;QACvC,OAAO,EAAE,GAAG,EAAE;YACZ,MAAM,OAAO,GAAG,WAAW,EAAE,CAAA;YAC7B,IAAI,OAAO;gBAAE,OAAO,EAAE,CAAA;QACxB,CAAC;KACF,CAAA;IACD,iBAAiB,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;IAC9B,OAAO,GAAG,EAAE;QACV,gBAAgB,CAAC,IAAI,CAAC,CAAA;IACxB,CAAC,CAAA;AACH,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,UAAU,uBAAuB;IACrC,MAAM,IAAI,GAAG,MAAM,CAAC,UAAU,CAAC,CAAC,aAA4B,CAAA;IAC5D,MAAM,OAAO,GAAG,GAA8B,EAAE;QAC9C,MAAM,KAAK,GAAG,cAAc,CAA4B,IAAI,CAAC,CAAA;QAC7D,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,MAAM,IAAI,KAAK,CACb,gFAAgF,CACjF,CAAA;QACH,CAAC;QACD,OAAO,KAAK,CAAA;IACd,CAAC,CAAA;IACD,OAAO;QACL,IAAI,OAAO;YACT,OAAO,OAAO,EAAE,CAAC,OAAO,CAAA;QAC1B,CAAC;KACF,CAAA;AACH,CAAC"}
@@ -0,0 +1,38 @@
1
+ /**
2
+ * The controlled-`checked` sync for the UI package's `Switch`, used by the
3
+ * sections that toggle one.
4
+ *
5
+ * React's controlled inputs mirror the `checked` prop on every re-render:
6
+ * the attribute is written once at mount and the PROPERTY follows the prop.
7
+ * The UI `Switch` mirrors the prop through the attribute instead, which is
8
+ * equivalent until a user click sets the native checkbox's dirty flag — after
9
+ * that, attribute writes no longer move the property. This helper reproduces
10
+ * React's split exactly: the property always follows the prop, the attribute
11
+ * stays as it was at mount.
12
+ *
13
+ * @module
14
+ */
15
+ /**
16
+ * Syncs one `Switch`'s hidden native checkbox after the binding pass.
17
+ */
18
+ export declare class ControlledSwitchSync {
19
+ private readonly switchHost;
20
+ /** The attribute state React froze at mount (null until the first sync). */
21
+ private mountedAttrChecked;
22
+ /** The hidden native checkbox (re-resolved while the view is rebuilt). */
23
+ private input;
24
+ /**
25
+ * Creates the sync for one switch.
26
+ * @param switchHost - The switch's host element (`mol-switch`).
27
+ */
28
+ constructor(switchHost: HTMLElement);
29
+ /**
30
+ * Applies React's property/attribute split for the given controlled value.
31
+ * Runs after the switch's own bindings (the owner's `ngAfterViewChecked`),
32
+ * so it settles the state the pass produced.
33
+ *
34
+ * @param checked - The controlled `checked` value this render shows.
35
+ */
36
+ sync(checked: boolean): void;
37
+ }
38
+ //# sourceMappingURL=controlled-switch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"controlled-switch.d.ts","sourceRoot":"","sources":["../src/controlled-switch.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH;;GAEG;AACH,qBAAa,oBAAoB;IAUnB,OAAO,CAAC,QAAQ,CAAC,UAAU;IATvC,4EAA4E;IAC5E,OAAO,CAAC,kBAAkB,CAAuB;IACjD,0EAA0E;IAC1E,OAAO,CAAC,KAAK,CAAgC;IAE7C;;;OAGG;gBAC0B,UAAU,EAAE,WAAW;IAEpD;;;;;;OAMG;IACH,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI;CAa7B"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * The controlled-`checked` sync for the UI package's `Switch`, used by the
3
+ * sections that toggle one.
4
+ *
5
+ * React's controlled inputs mirror the `checked` prop on every re-render:
6
+ * the attribute is written once at mount and the PROPERTY follows the prop.
7
+ * The UI `Switch` mirrors the prop through the attribute instead, which is
8
+ * equivalent until a user click sets the native checkbox's dirty flag — after
9
+ * that, attribute writes no longer move the property. This helper reproduces
10
+ * React's split exactly: the property always follows the prop, the attribute
11
+ * stays as it was at mount.
12
+ *
13
+ * @module
14
+ */
15
+ /**
16
+ * Syncs one `Switch`'s hidden native checkbox after the binding pass.
17
+ */
18
+ export class ControlledSwitchSync {
19
+ switchHost;
20
+ /** The attribute state React froze at mount (null until the first sync). */
21
+ mountedAttrChecked = null;
22
+ /** The hidden native checkbox (re-resolved while the view is rebuilt). */
23
+ input = null;
24
+ /**
25
+ * Creates the sync for one switch.
26
+ * @param switchHost - The switch's host element (`mol-switch`).
27
+ */
28
+ constructor(switchHost) {
29
+ this.switchHost = switchHost;
30
+ }
31
+ /**
32
+ * Applies React's property/attribute split for the given controlled value.
33
+ * Runs after the switch's own bindings (the owner's `ngAfterViewChecked`),
34
+ * so it settles the state the pass produced.
35
+ *
36
+ * @param checked - The controlled `checked` value this render shows.
37
+ */
38
+ sync(checked) {
39
+ if (!this.input || !this.input.isConnected) {
40
+ this.input = this.switchHost.querySelector('input');
41
+ }
42
+ const input = this.input;
43
+ if (!input)
44
+ return;
45
+ if (this.mountedAttrChecked === null)
46
+ this.mountedAttrChecked = checked;
47
+ // React's re-render: the property mirrors the prop…
48
+ input.checked = checked;
49
+ // …and the attribute keeps its mount-time state.
50
+ if (this.mountedAttrChecked)
51
+ input.setAttribute('checked', '');
52
+ else
53
+ input.removeAttribute('checked');
54
+ }
55
+ }
56
+ //# sourceMappingURL=controlled-switch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"controlled-switch.js","sourceRoot":"","sources":["../src/controlled-switch.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH;;GAEG;AACH,MAAM,OAAO,oBAAoB;IAUF;IAT7B,4EAA4E;IACpE,kBAAkB,GAAmB,IAAI,CAAA;IACjD,0EAA0E;IAClE,KAAK,GAA4B,IAAI,CAAA;IAE7C;;;OAGG;IACH,YAA6B,UAAuB;QAAvB,eAAU,GAAV,UAAU,CAAa;IAAG,CAAC;IAExD;;;;;;OAMG;IACH,IAAI,CAAC,OAAgB;QACnB,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC;YAC3C,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC,OAAO,CAAC,CAAA;QACrD,CAAC;QACD,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAA;QACxB,IAAI,CAAC,KAAK;YAAE,OAAM;QAClB,IAAI,IAAI,CAAC,kBAAkB,KAAK,IAAI;YAAE,IAAI,CAAC,kBAAkB,GAAG,OAAO,CAAA;QACvE,oDAAoD;QACpD,KAAK,CAAC,OAAO,GAAG,OAAO,CAAA;QACvB,iDAAiD;QACjD,IAAI,IAAI,CAAC,kBAAkB;YAAE,KAAK,CAAC,YAAY,CAAC,SAAS,EAAE,EAAE,CAAC,CAAA;;YACzD,KAAK,CAAC,eAAe,CAAC,SAAS,CAAC,CAAA;IACvC,CAAC;CACF"}
@@ -0,0 +1,88 @@
1
+ import { type TemplateRef } from '@angular/core';
2
+ import type { UIClassMap } from '@molecule/app-ui';
3
+ import type { Device } from './types.js';
4
+ import * as i0 from "@angular/core";
5
+ /**
6
+ * DevicesSection component.
7
+ *
8
+ * Devices section — lists the user's registered devices and lets them
9
+ * revoke (sign out) any device other than the one they're currently using.
10
+ * The host IS the `<section>` React renders.
11
+ *
12
+ * Revoking deletes the device row (`DELETE /api/devices/:id`). The API's
13
+ * authorization layer enforces server-side revocation: it rejects that
14
+ * device's session the next time it makes a request (within the
15
+ * device-exists cache TTL), so the removed device is actually signed out —
16
+ * not just hidden from the list. The current device is labelled
17
+ * "This device" and is not revocable here (use Sign out for the current
18
+ * session). Recreates molecule v1's device-revocation behaviour.
19
+ *
20
+ * Apps that want a different trailing element per row can pass a
21
+ * `renderRowIcon` template (its context carries the device as `$implicit`
22
+ * and `a0`, the way the conformance kit maps a React render function), which
23
+ * then replaces the built-in revoke control; pass an empty template to
24
+ * suppress it entirely.
25
+ */
26
+ export declare class DevicesSection {
27
+ /**
28
+ * A custom trailing element per row (React's `renderRowIcon` callback).
29
+ * The template's context carries the device as `$implicit` / `a0`; giving
30
+ * one replaces the built-in revoke control.
31
+ */
32
+ renderRowIcon?: TemplateRef<unknown> | null;
33
+ /** Reactive translation, read in the injection context. */
34
+ protected readonly i18n: import("@molecule/app-angular").UseTranslationResult;
35
+ /** The translation function for the template. */
36
+ protected t: (key: string, values?: import("@molecule/app-i18n").InterpolationValues, options?: import("@molecule/app-i18n").TranslateOptions) => string;
37
+ private readonly http;
38
+ /** The registered devices. */
39
+ protected readonly devices: import("@angular/core").WritableSignal<Device[]>;
40
+ /** Whether the device list is loading. */
41
+ protected readonly loading: import("@angular/core").WritableSignal<boolean>;
42
+ /** The id of the row showing its revoke confirmation. */
43
+ protected readonly confirmingId: import("@angular/core").WritableSignal<string | null>;
44
+ /** The id of the device whose revoke request is running. */
45
+ protected readonly revokingId: import("@angular/core").WritableSignal<string | null>;
46
+ /** The bonded ClassMap (styling tokens resolve at render time). */
47
+ protected readonly cm: UIClassMap;
48
+ /**
49
+ * Whether one row shows its revoke confirmation.
50
+ * @param device - The row's device.
51
+ * @returns True when the row is confirming.
52
+ */
53
+ protected isConfirming(device: Device): boolean;
54
+ /**
55
+ * Whether one row's revoke request is running.
56
+ * @param device - The row's device.
57
+ * @returns True when the row is revoking.
58
+ */
59
+ protected isRevoking(device: Device): boolean;
60
+ /**
61
+ * The template context for one row's custom renderer (the way the
62
+ * conformance kit maps a React render function: `$implicit` = the first
63
+ * argument, `a0`… the argument list).
64
+ * @param device - The row's device.
65
+ * @returns The template context.
66
+ */
67
+ protected rowContext(device: Device): Record<string, unknown>;
68
+ /**
69
+ * Loads the devices (React's `load`): GET /api/devices responds with the
70
+ * ARRAY itself (see the device resource's query handler) — response.data IS
71
+ * the rows. This used to read `response.data.data`, which is always
72
+ * undefined for that shape, so the section rendered "No devices" for
73
+ * everyone. Devices endpoint is optional; the section renders empty when
74
+ * unavailable.
75
+ */
76
+ private load;
77
+ /** Loads once on mount (React's mount effect). */
78
+ constructor();
79
+ /**
80
+ * Signs one device out and reloads (React's `revoke`); best-effort — the
81
+ * row is kept so the user can retry the revoke.
82
+ * @param id - The device row's id.
83
+ */
84
+ protected revoke(id: string): Promise<void>;
85
+ static ɵfac: i0.ɵɵFactoryDeclaration<DevicesSection, never>;
86
+ static ɵcmp: i0.ɵɵComponentDeclaration<DevicesSection, "section[mol-settings-devices]", never, { "renderRowIcon": { "alias": "renderRowIcon"; "required": false; }; }, {}, never, never, true, never>;
87
+ }
88
+ //# sourceMappingURL=devices-section.component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"devices-section.component.d.ts","sourceRoot":"","sources":["../src/devices-section.component.ts"],"names":[],"mappings":"AAOA,OAAO,EAAyC,KAAK,WAAW,EAAE,MAAM,eAAe,CAAA;AAGvF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAIlD,OAAO,KAAK,EAA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