@energinet/watt 1.0.7 → 1.1.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.
@@ -21,6 +21,9 @@ export type WattDrawerSize = 'small' | 'normal' | 'large';
21
21
  export declare class WattDrawerComponent implements OnDestroy {
22
22
  private elementRef;
23
23
  private overlayContainer;
24
+ private content;
25
+ private heading;
26
+ private topBar;
24
27
  private cdkTrapFocus;
25
28
  private bypassClickCheck;
26
29
  private writableIsOpen;
@@ -40,6 +43,8 @@ export declare class WattDrawerComponent implements OnDestroy {
40
43
  key: import("@angular/core").InputSignal<unknown>;
41
44
  /** Whether the drawer should show a loading state. */
42
45
  loading: import("@angular/core").InputSignal<boolean>;
46
+ /** Adds a brief animation to indicate that the content has changed. */
47
+ animateOnKeyChange: import("@angular/core").InputSignal<boolean>;
43
48
  /** Emits whenever the drawer is fully closed. */
44
49
  closed: import("@angular/core").OutputEmitterRef<void>;
45
50
  /** Whether the drawer is open. */
@@ -56,6 +61,6 @@ export declare class WattDrawerComponent implements OnDestroy {
56
61
  /** Closes the drawer. */
57
62
  close(): void;
58
63
  static ɵfac: i0.ɵɵFactoryDeclaration<WattDrawerComponent, never>;
59
- static ɵcmp: i0.ɵɵComponentDeclaration<WattDrawerComponent, "watt-drawer", never, { "size": { "alias": "size"; "required": false; "isSignal": true; }; "autoOpen": { "alias": "autoOpen"; "required": false; "isSignal": true; }; "key": { "alias": "key"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; }, { "closed": "closed"; }, never, ["watt-drawer-topbar", "watt-drawer-heading", "watt-drawer-actions", "watt-drawer-content"], true, never>;
64
+ static ɵcmp: i0.ɵɵComponentDeclaration<WattDrawerComponent, "watt-drawer", never, { "size": { "alias": "size"; "required": false; "isSignal": true; }; "autoOpen": { "alias": "autoOpen"; "required": false; "isSignal": true; }; "key": { "alias": "key"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "animateOnKeyChange": { "alias": "animateOnKeyChange"; "required": false; "isSignal": true; }; }, { "closed": "closed"; }, ["content", "heading", "topBar"], ["watt-drawer-topbar", "watt-drawer-heading", "watt-drawer-actions", "watt-drawer-content"], true, never>;
60
65
  }
61
66
  export declare const WATT_DRAWER: (typeof WattDrawerTopbarComponent)[];
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Component, ViewEncapsulation, inject, ElementRef, viewChild, signal, input, booleanAttribute, output, afterRenderEffect, untracked, ChangeDetectionStrategy } from '@angular/core';
2
+ import { Component, ViewEncapsulation, inject, ElementRef, contentChild, viewChild, signal, input, booleanAttribute, output, effect, untracked, ChangeDetectionStrategy } from '@angular/core';
3
3
  import { OverlayContainer } from '@angular/cdk/overlay';
4
4
  import * as i1 from '@angular/cdk/a11y';
5
5
  import { CdkTrapFocus, A11yModule } from '@angular/cdk/a11y';
@@ -134,9 +134,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.1", ngImpor
134
134
  * limitations under the License.
135
135
  */
136
136
  //#endregion
137
+ const APPEAR_ANIMATION_DELAY = 250;
138
+ const APPEAR_ANIMATION_FRAMES = {
139
+ transform: ['translateX(30px)', 'translateX(0)'],
140
+ opacity: ['0', '1'],
141
+ };
137
142
  class WattDrawerComponent {
138
143
  elementRef = inject(ElementRef);
139
144
  overlayContainer = inject(OverlayContainer);
145
+ content = contentChild(WattDrawerContentComponent, { read: ElementRef });
146
+ heading = contentChild(WattDrawerHeadingComponent, { read: ElementRef });
147
+ topBar = contentChild(WattDrawerTopbarComponent, { read: ElementRef });
140
148
  cdkTrapFocus = viewChild.required(CdkTrapFocus);
141
149
  bypassClickCheck = false;
142
150
  writableIsOpen = signal(false);
@@ -158,15 +166,26 @@ class WattDrawerComponent {
158
166
  key = input();
159
167
  /** Whether the drawer should show a loading state. */
160
168
  loading = input(false);
169
+ /** Adds a brief animation to indicate that the content has changed. */
170
+ animateOnKeyChange = input(false);
161
171
  /** Emits whenever the drawer is fully closed. */
162
172
  closed = output();
163
173
  /** Whether the drawer is open. */
164
174
  isOpen = this.writableIsOpen.asReadonly();
165
175
  constructor() {
166
- afterRenderEffect(() => {
176
+ effect(() => {
167
177
  this.key();
168
178
  if (this.autoOpen())
169
179
  this.open();
180
+ if (!this.animateOnKeyChange())
181
+ return;
182
+ untracked(() => {
183
+ if (!this.isOpen())
184
+ return;
185
+ this.content()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);
186
+ this.heading()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);
187
+ this.topBar()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);
188
+ });
170
189
  });
171
190
  }
172
191
  /** @ignore */
@@ -227,7 +246,7 @@ class WattDrawerComponent {
227
246
  this.writableIsOpen.set(false);
228
247
  }
229
248
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: WattDrawerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
230
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.1", type: WattDrawerComponent, isStandalone: true, selector: "watt-drawer", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, autoOpen: { classPropertyName: "autoOpen", publicName: "autoOpen", isSignal: true, isRequired: false, transformFunction: null }, key: { classPropertyName: "key", publicName: "key", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closed: "closed" }, host: { listeners: { "document:click": "handleDocumentClick($event)", "keydown.escape": "handleEscKeyPressed()" } }, viewQueries: [{ propertyName: "cdkTrapFocus", first: true, predicate: CdkTrapFocus, descendants: true, isSignal: true }], ngImport: i0, template: "<!--\n@license\nCopyright 2020 Energinet DataHub A/S\n\nLicensed under the Apache License, Version 2.0 (the \"License2\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-->\n<mat-drawer-container class=\"watt-drawer-container\" [hasBackdrop]=\"false\">\n <mat-drawer\n class=\"watt-drawer watt-space-inset-s watt-drawer--{{ size() }}\"\n mode=\"side\"\n position=\"end\"\n [opened]=\"isOpen()\"\n (closed)=\"closed.emit()\"\n [disableClose]=\"true\"\n [autoFocus]=\"true\"\n [cdkTrapFocus]=\"true\"\n >\n <div class=\"watt-drawer__grid-container\">\n <header>\n <ng-content select=\"watt-drawer-topbar\" />\n <watt-button class=\"close-btn\" variant=\"icon\" icon=\"close\" (click)=\"close()\" />\n </header>\n\n <article class=\"watt-drawer__content\">\n <div class=\"watt-drawer__actions\">\n <ng-content select=\"watt-drawer-heading\" />\n <ng-content select=\"watt-drawer-actions\" />\n </div>\n <ng-content select=\"watt-drawer-content\" />\n </article>\n </div>\n\n @if (loading()) {\n <div class=\"watt-drawer__spinner\">\n <watt-spinner />\n </div>\n }\n </mat-drawer>\n</mat-drawer-container>\n", styles: [":host{display:block}.watt-drawer-container{box-shadow:0 4px 64px 3px #2e323440;height:100vh;position:fixed;right:0;top:0;width:auto;z-index:500}.watt-drawer{padding:0}.watt-drawer header{display:flex;justify-content:flex-end}.watt-drawer header .close-btn{align-self:center}.watt-drawer__grid-container{display:grid;grid-template-rows:auto 1fr;height:100%}.watt-drawer--small{width:460px;max-width:100vw}.watt-drawer--small .watt-drawer__actions{margin-bottom:var(--watt-space-m)}.watt-drawer--normal{width:888px;max-width:100vw}.watt-drawer--large{width:1174px;max-width:100vw}.watt-drawer__content{display:grid;grid-template-rows:auto 1fr;overflow-y:auto}.watt-drawer__actions{display:flex;border-bottom:1px solid var(--watt-color-neutral-grey-300);padding-bottom:var(--watt-space-m)}.watt-drawer__spinner{z-index:1;position:absolute;inset:0;display:flex;justify-content:center;align-items:center;background-color:var(--watt-color-neutral-white);opacity:.5}\n"], dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i1.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i2.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i2.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: WattButtonComponent, selector: "watt-button", inputs: ["icon", "variant", "type", "formId", "disabled", "loading"] }, { kind: "component", type: WattSpinnerComponent, selector: "watt-spinner", inputs: ["diameter", "strokeWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
249
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.1", type: WattDrawerComponent, isStandalone: true, selector: "watt-drawer", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, autoOpen: { classPropertyName: "autoOpen", publicName: "autoOpen", isSignal: true, isRequired: false, transformFunction: null }, key: { classPropertyName: "key", publicName: "key", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, animateOnKeyChange: { classPropertyName: "animateOnKeyChange", publicName: "animateOnKeyChange", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closed: "closed" }, host: { listeners: { "document:click": "handleDocumentClick($event)", "keydown.escape": "handleEscKeyPressed()" } }, queries: [{ propertyName: "content", first: true, predicate: WattDrawerContentComponent, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "heading", first: true, predicate: WattDrawerHeadingComponent, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "topBar", first: true, predicate: WattDrawerTopbarComponent, descendants: true, read: ElementRef, isSignal: true }], viewQueries: [{ propertyName: "cdkTrapFocus", first: true, predicate: CdkTrapFocus, descendants: true, isSignal: true }], ngImport: i0, template: "<!--\n@license\nCopyright 2020 Energinet DataHub A/S\n\nLicensed under the Apache License, Version 2.0 (the \"License2\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-->\n<mat-drawer-container class=\"watt-drawer-container\" [hasBackdrop]=\"false\">\n <mat-drawer\n class=\"watt-drawer watt-space-inset-s watt-drawer--{{ size() }}\"\n mode=\"side\"\n position=\"end\"\n [opened]=\"isOpen()\"\n (closed)=\"closed.emit()\"\n [disableClose]=\"true\"\n [autoFocus]=\"true\"\n [cdkTrapFocus]=\"true\"\n >\n <div class=\"watt-drawer__grid-container\">\n <header>\n <ng-content select=\"watt-drawer-topbar\" />\n <watt-button class=\"close-btn\" variant=\"icon\" icon=\"close\" (click)=\"close()\" />\n </header>\n\n <article class=\"watt-drawer__content\">\n <div class=\"watt-drawer__actions\">\n <ng-content select=\"watt-drawer-heading\" />\n <ng-content select=\"watt-drawer-actions\" />\n </div>\n <ng-content select=\"watt-drawer-content\" />\n </article>\n </div>\n\n @if (loading()) {\n <div class=\"watt-drawer__spinner\">\n <watt-spinner />\n </div>\n }\n </mat-drawer>\n</mat-drawer-container>\n", styles: [":host{display:block}.watt-drawer-container{box-shadow:0 4px 64px 3px #2e323440;height:100vh;position:fixed;right:0;top:0;width:auto;z-index:500}.watt-drawer{padding:0}.watt-drawer header{display:flex;justify-content:flex-end}.watt-drawer header .close-btn{align-self:center}.watt-drawer__grid-container{display:grid;grid-template-rows:auto 1fr;height:100%}.watt-drawer--small{width:460px;max-width:100vw}.watt-drawer--small .watt-drawer__actions{margin-bottom:var(--watt-space-m)}.watt-drawer--normal{width:888px;max-width:100vw}.watt-drawer--large{width:1174px;max-width:100vw}.watt-drawer__content{display:grid;grid-template-rows:auto 1fr;overflow-y:auto}.watt-drawer__actions{display:flex;border-bottom:1px solid var(--watt-color-neutral-grey-300);padding-bottom:var(--watt-space-m)}.watt-drawer__spinner{z-index:1;position:absolute;inset:0;display:flex;justify-content:center;align-items:center;background-color:var(--watt-color-neutral-white);opacity:.5}\n"], dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i1.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i2.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i2.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: WattButtonComponent, selector: "watt-button", inputs: ["icon", "variant", "type", "formId", "disabled", "loading"] }, { kind: "component", type: WattSpinnerComponent, selector: "watt-spinner", inputs: ["diameter", "strokeWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
231
250
  }
232
251
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: WattDrawerComponent, decorators: [{
233
252
  type: Component,
@@ -1 +1 @@
1
- {"version":3,"file":"energinet-watt-drawer.mjs","sources":["../../../libs/watt/package/drawer/watt-drawer-topbar.component.ts","../../../libs/watt/package/drawer/watt-drawer-actions.component.ts","../../../libs/watt/package/drawer/watt-drawer-content.component.ts","../../../libs/watt/package/drawer/watt-drawer-heading.component.ts","../../../libs/watt/package/drawer/watt-drawer.component.ts","../../../libs/watt/package/drawer/watt-drawer.component.html","../../../libs/watt/package/drawer/index.ts","../../../libs/watt/package/drawer/energinet-watt-drawer.ts"],"sourcesContent":["//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-topbar',\n template: `<ng-content />`,\n styleUrls: ['./watt-drawer-topbar.component.scss'],\n})\nexport class WattDrawerTopbarComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-actions',\n styles: `\n :host {\n flex-shrink: 0;\n display: flex;\n justify-content: flex-end;\n align-items: flex-start;\n gap: var(--watt-space-m);\n margin-left: auto;\n margin-right: var(--watt-space-ml);\n }\n `,\n template: `<ng-content select=\"watt-button\" />`,\n})\nexport class WattDrawerActionsComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-content',\n template: `<ng-content />`,\n styles: [\n `\n :host {\n overflow: auto;\n }\n `,\n ],\n})\nexport class WattDrawerContentComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-heading',\n encapsulation: ViewEncapsulation.None,\n template: `<ng-content />`,\n styles: [\n `\n watt-drawer-heading {\n margin-left: var(--watt-space-ml);\n }\n\n watt-drawer-heading h1,\n watt-drawer-heading h2,\n watt-drawer-heading h3,\n watt-drawer-heading h4,\n watt-drawer-heading h5,\n watt-drawer-heading h6 {\n margin: 0;\n line-height: 48px !important; /* align with actions */\n }\n `,\n ],\n})\nexport class WattDrawerHeadingComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport {\n inject,\n input,\n output,\n Component,\n OnDestroy,\n viewChild,\n ElementRef,\n ChangeDetectionStrategy,\n signal,\n afterRenderEffect,\n untracked,\n booleanAttribute,\n} from '@angular/core';\n\nimport { OverlayContainer } from '@angular/cdk/overlay';\nimport { CdkTrapFocus, A11yModule } from '@angular/cdk/a11y';\nimport { MatSidenavModule } from '@angular/material/sidenav';\n\nimport { WattButtonComponent } from '@energinet/watt/button';\nimport { WattSpinnerComponent } from '@energinet/watt/spinner';\n\nimport { WattDrawerTopbarComponent } from './watt-drawer-topbar.component';\nimport { WattDrawerActionsComponent } from './watt-drawer-actions.component';\nimport { WattDrawerContentComponent } from './watt-drawer-content.component';\nimport { WattDrawerHeadingComponent } from './watt-drawer-heading.component';\n\nexport type WattDrawerSize = 'small' | 'normal' | 'large';\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'watt-drawer',\n styleUrls: ['./watt-drawer.component.scss'],\n templateUrl: './watt-drawer.component.html',\n host: {\n '(document:click)': 'handleDocumentClick($event)',\n '(keydown.escape)': 'handleEscKeyPressed()',\n },\n imports: [A11yModule, MatSidenavModule, WattButtonComponent, WattSpinnerComponent],\n})\nexport class WattDrawerComponent implements OnDestroy {\n private elementRef = inject(ElementRef);\n private overlayContainer = inject(OverlayContainer);\n private cdkTrapFocus = viewChild.required(CdkTrapFocus);\n private bypassClickCheck = false;\n private writableIsOpen = signal(false);\n\n // Multiple drawers open at the same time is not allowed. This keeps track of\n // the currently opened drawer and closes it when a new drawer is opened.\n private static currentDrawer?: WattDrawerComponent;\n\n /** Used to adjust drawer size to best fit the content. */\n size = input<WattDrawerSize>('normal');\n\n /**\n * Whether the drawer should open automatically. If `key` is provided and\n * `autoOpen` is true, the drawer will open every time the key changes.\n */\n autoOpen = input(false, { transform: booleanAttribute });\n\n /**\n * Used to track the current drawer when reusing the same drawer instance to\n * render different content. This is required when interactions outside the\n * drawer should result in updating the drawer's content instead of closing it.\n */\n key = input<unknown>();\n\n /** Whether the drawer should show a loading state. */\n loading = input(false);\n\n /** Emits whenever the drawer is fully closed. */\n closed = output<void>();\n\n /** Whether the drawer is open. */\n isOpen = this.writableIsOpen.asReadonly();\n\n constructor() {\n afterRenderEffect(() => {\n this.key();\n if (this.autoOpen()) this.open();\n });\n }\n\n /** @ignore */\n handleDocumentClick(event: MouseEvent) {\n // Prevent closing when the click triggered a call to `open`\n if (this.bypassClickCheck) return;\n\n // Check if the click originated from within the drawer element\n const isClickInside = this.elementRef.nativeElement.contains(event.target);\n if (isClickInside) return;\n\n // Check if the click originated from within an overlay (such as a modal)\n const overlayContainerEl = this.overlayContainer.getContainerElement();\n const isOverlayClick = overlayContainerEl.contains(event.target as Node);\n if (isOverlayClick) return;\n\n // Click is allowed to close the drawer now\n this.close();\n }\n\n /** @ignore */\n handleEscKeyPressed() {\n this.close();\n }\n\n /** @ignore */\n ngOnDestroy(): void {\n if (WattDrawerComponent.currentDrawer === this) {\n WattDrawerComponent.currentDrawer = undefined;\n }\n }\n\n /** Opens the drawer. Subsequent calls are ignored while the drawer is opened. */\n open() {\n // Trap focus whenever open is called. This doesn't work on the\n // initial call (when first opening the drawer), but this is\n // handled by the autoFocus property on mat-drawer.\n this.cdkTrapFocus().focusTrap.focusInitialElementWhenReady();\n\n // Disable click outside check until the current event loop is finished.\n // This might seem hackish, but the order of execution is stable here.\n // Also prevents an issue when the drawer is destroyed and then recreated,\n // causing the click outside check to trigger immediately if the drawer\n // is created and opened in response to a click event.\n this.bypassClickCheck = true;\n setTimeout(() => {\n this.bypassClickCheck = false;\n }, 0);\n\n // Without `untracked`, if this is called in a reactive context (such as an `effect`),\n // it will be triggered twice due to `isOpen` being tracked and immediately updated.\n if (untracked(this.isOpen)) return;\n WattDrawerComponent.currentDrawer?.close();\n WattDrawerComponent.currentDrawer = this;\n this.writableIsOpen.set(true);\n }\n\n /** Closes the drawer. */\n close() {\n if (!untracked(this.isOpen)) return;\n WattDrawerComponent.currentDrawer = undefined;\n this.writableIsOpen.set(false);\n }\n}\n\nexport const WATT_DRAWER = [\n WattDrawerComponent,\n WattDrawerTopbarComponent,\n WattDrawerActionsComponent,\n WattDrawerContentComponent,\n WattDrawerHeadingComponent,\n];\n","<!--\n@license\nCopyright 2020 Energinet DataHub A/S\n\nLicensed under the Apache License, Version 2.0 (the \"License2\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-->\n<mat-drawer-container class=\"watt-drawer-container\" [hasBackdrop]=\"false\">\n <mat-drawer\n class=\"watt-drawer watt-space-inset-s watt-drawer--{{ size() }}\"\n mode=\"side\"\n position=\"end\"\n [opened]=\"isOpen()\"\n (closed)=\"closed.emit()\"\n [disableClose]=\"true\"\n [autoFocus]=\"true\"\n [cdkTrapFocus]=\"true\"\n >\n <div class=\"watt-drawer__grid-container\">\n <header>\n <ng-content select=\"watt-drawer-topbar\" />\n <watt-button class=\"close-btn\" variant=\"icon\" icon=\"close\" (click)=\"close()\" />\n </header>\n\n <article class=\"watt-drawer__content\">\n <div class=\"watt-drawer__actions\">\n <ng-content select=\"watt-drawer-heading\" />\n <ng-content select=\"watt-drawer-actions\" />\n </div>\n <ng-content select=\"watt-drawer-content\" />\n </article>\n </div>\n\n @if (loading()) {\n <div class=\"watt-drawer__spinner\">\n <watt-spinner />\n </div>\n }\n </mat-drawer>\n</mat-drawer-container>\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nexport { WattDrawerTopbarComponent } from './watt-drawer-topbar.component';\nexport { WattDrawerActionsComponent } from './watt-drawer-actions.component';\nexport { WattDrawerContentComponent } from './watt-drawer-content.component';\nexport { WattDrawerHeadingComponent } from './watt-drawer-heading.component';\nexport { WattDrawerComponent, WATT_DRAWER, WattDrawerSize } from './watt-drawer.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAAA;AACA;;;;;;;;;;;;;;;AAeG;AACH;MAQa,yBAAyB,CAAA;uGAAzB,yBAAyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAzB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,yBAAyB,8EAH1B,CAAgB,cAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,iLAAA,CAAA,EAAA,CAAA;;2FAGf,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBALrC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,oBAAoB,YACpB,CAAgB,cAAA,CAAA,EAAA,MAAA,EAAA,CAAA,iLAAA,CAAA,EAAA;;;ACtB5B;AACA;;;;;;;;;;;;;;;AAeG;AACH;MAkBa,0BAA0B,CAAA;uGAA1B,0BAA0B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA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AAA,EAAA,CAAA;;2FAEtE,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAX/B,SAAS;AACS,YAAA,IAAA,EAAA,CAAA,EAAA,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACrC,QAAA,EAAA,aAAa,EAGjB,IAAA,EAAA;AACJ,wBAAA,kBAAkB,EAAE,6BAA6B;AACjD,wBAAA,kBAAkB,EAAE,uBAAuB;qBAC5C,EACQ,OAAA,EAAA,CAAC,UAAU,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,oBAAoB,CAAC,EAAA,QAAA,EAAA,6nDAAA,EAAA,MAAA,EAAA,CAAA,m8BAAA,CAAA,EAAA;;AA4GvE,MAAA,WAAW,GAAG;IACzB,mBAAmB;IACnB,yBAAyB;IACzB,0BAA0B;IAC1B,0BAA0B;IAC1B,0BAA0B;;;AEzK5B;AACA;;;;;;;;;;;;;;;AAeG;AACH;;ACjBA;;AAEG;;;;"}
1
+ {"version":3,"file":"energinet-watt-drawer.mjs","sources":["../../../libs/watt/package/drawer/watt-drawer-topbar.component.ts","../../../libs/watt/package/drawer/watt-drawer-actions.component.ts","../../../libs/watt/package/drawer/watt-drawer-content.component.ts","../../../libs/watt/package/drawer/watt-drawer-heading.component.ts","../../../libs/watt/package/drawer/watt-drawer.component.ts","../../../libs/watt/package/drawer/watt-drawer.component.html","../../../libs/watt/package/drawer/index.ts","../../../libs/watt/package/drawer/energinet-watt-drawer.ts"],"sourcesContent":["//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-topbar',\n template: `<ng-content />`,\n styleUrls: ['./watt-drawer-topbar.component.scss'],\n})\nexport class WattDrawerTopbarComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-actions',\n styles: `\n :host {\n flex-shrink: 0;\n display: flex;\n justify-content: flex-end;\n align-items: flex-start;\n gap: var(--watt-space-m);\n margin-left: auto;\n margin-right: var(--watt-space-ml);\n }\n `,\n template: `<ng-content select=\"watt-button\" />`,\n})\nexport class WattDrawerActionsComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-content',\n template: `<ng-content />`,\n styles: [\n `\n :host {\n overflow: auto;\n }\n `,\n ],\n})\nexport class WattDrawerContentComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport { Component, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector: 'watt-drawer-heading',\n encapsulation: ViewEncapsulation.None,\n template: `<ng-content />`,\n styles: [\n `\n watt-drawer-heading {\n margin-left: var(--watt-space-ml);\n }\n\n watt-drawer-heading h1,\n watt-drawer-heading h2,\n watt-drawer-heading h3,\n watt-drawer-heading h4,\n watt-drawer-heading h5,\n watt-drawer-heading h6 {\n margin: 0;\n line-height: 48px !important; /* align with actions */\n }\n `,\n ],\n})\nexport class WattDrawerHeadingComponent {}\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nimport {\n inject,\n input,\n output,\n Component,\n OnDestroy,\n viewChild,\n ElementRef,\n ChangeDetectionStrategy,\n signal,\n untracked,\n booleanAttribute,\n contentChild,\n effect,\n} from '@angular/core';\n\nimport { OverlayContainer } from '@angular/cdk/overlay';\nimport { CdkTrapFocus, A11yModule } from '@angular/cdk/a11y';\nimport { MatSidenavModule } from '@angular/material/sidenav';\n\nimport { WattButtonComponent } from '@energinet/watt/button';\nimport { WattSpinnerComponent } from '@energinet/watt/spinner';\n\nimport { WattDrawerTopbarComponent } from './watt-drawer-topbar.component';\nimport { WattDrawerActionsComponent } from './watt-drawer-actions.component';\nimport { WattDrawerContentComponent } from './watt-drawer-content.component';\nimport { WattDrawerHeadingComponent } from './watt-drawer-heading.component';\n\nexport type WattDrawerSize = 'small' | 'normal' | 'large';\n\nconst APPEAR_ANIMATION_DELAY = 250;\nconst APPEAR_ANIMATION_FRAMES = {\n transform: ['translateX(30px)', 'translateX(0)'],\n opacity: ['0', '1'],\n};\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'watt-drawer',\n styleUrls: ['./watt-drawer.component.scss'],\n templateUrl: './watt-drawer.component.html',\n host: {\n '(document:click)': 'handleDocumentClick($event)',\n '(keydown.escape)': 'handleEscKeyPressed()',\n },\n imports: [A11yModule, MatSidenavModule, WattButtonComponent, WattSpinnerComponent],\n})\nexport class WattDrawerComponent implements OnDestroy {\n private elementRef = inject(ElementRef);\n private overlayContainer = inject(OverlayContainer);\n private content = contentChild(WattDrawerContentComponent, { read: ElementRef });\n private heading = contentChild(WattDrawerHeadingComponent, { read: ElementRef });\n private topBar = contentChild(WattDrawerTopbarComponent, { read: ElementRef });\n private cdkTrapFocus = viewChild.required(CdkTrapFocus);\n private bypassClickCheck = false;\n private writableIsOpen = signal(false);\n\n // Multiple drawers open at the same time is not allowed. This keeps track of\n // the currently opened drawer and closes it when a new drawer is opened.\n private static currentDrawer?: WattDrawerComponent;\n\n /** Used to adjust drawer size to best fit the content. */\n size = input<WattDrawerSize>('normal');\n\n /**\n * Whether the drawer should open automatically. If `key` is provided and\n * `autoOpen` is true, the drawer will open every time the key changes.\n */\n autoOpen = input(false, { transform: booleanAttribute });\n\n /**\n * Used to track the current drawer when reusing the same drawer instance to\n * render different content. This is required when interactions outside the\n * drawer should result in updating the drawer's content instead of closing it.\n */\n key = input<unknown>();\n\n /** Whether the drawer should show a loading state. */\n loading = input(false);\n\n /** Adds a brief animation to indicate that the content has changed. */\n animateOnKeyChange = input(false);\n\n /** Emits whenever the drawer is fully closed. */\n closed = output<void>();\n\n /** Whether the drawer is open. */\n isOpen = this.writableIsOpen.asReadonly();\n\n constructor() {\n effect(() => {\n this.key();\n if (this.autoOpen()) this.open();\n if (!this.animateOnKeyChange()) return;\n untracked(() => {\n if (!this.isOpen()) return;\n this.content()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);\n this.heading()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);\n this.topBar()?.nativeElement.animate(APPEAR_ANIMATION_FRAMES, APPEAR_ANIMATION_DELAY);\n });\n });\n }\n\n /** @ignore */\n handleDocumentClick(event: MouseEvent) {\n // Prevent closing when the click triggered a call to `open`\n if (this.bypassClickCheck) return;\n\n // Check if the click originated from within the drawer element\n const isClickInside = this.elementRef.nativeElement.contains(event.target);\n if (isClickInside) return;\n\n // Check if the click originated from within an overlay (such as a modal)\n const overlayContainerEl = this.overlayContainer.getContainerElement();\n const isOverlayClick = overlayContainerEl.contains(event.target as Node);\n if (isOverlayClick) return;\n\n // Click is allowed to close the drawer now\n this.close();\n }\n\n /** @ignore */\n handleEscKeyPressed() {\n this.close();\n }\n\n /** @ignore */\n ngOnDestroy(): void {\n if (WattDrawerComponent.currentDrawer === this) {\n WattDrawerComponent.currentDrawer = undefined;\n }\n }\n\n /** Opens the drawer. Subsequent calls are ignored while the drawer is opened. */\n open() {\n // Trap focus whenever open is called. This doesn't work on the\n // initial call (when first opening the drawer), but this is\n // handled by the autoFocus property on mat-drawer.\n this.cdkTrapFocus().focusTrap.focusInitialElementWhenReady();\n\n // Disable click outside check until the current event loop is finished.\n // This might seem hackish, but the order of execution is stable here.\n // Also prevents an issue when the drawer is destroyed and then recreated,\n // causing the click outside check to trigger immediately if the drawer\n // is created and opened in response to a click event.\n this.bypassClickCheck = true;\n setTimeout(() => {\n this.bypassClickCheck = false;\n }, 0);\n\n // Without `untracked`, if this is called in a reactive context (such as an `effect`),\n // it will be triggered twice due to `isOpen` being tracked and immediately updated.\n if (untracked(this.isOpen)) return;\n WattDrawerComponent.currentDrawer?.close();\n WattDrawerComponent.currentDrawer = this;\n this.writableIsOpen.set(true);\n }\n\n /** Closes the drawer. */\n close() {\n if (!untracked(this.isOpen)) return;\n WattDrawerComponent.currentDrawer = undefined;\n this.writableIsOpen.set(false);\n }\n}\n\nexport const WATT_DRAWER = [\n WattDrawerComponent,\n WattDrawerTopbarComponent,\n WattDrawerActionsComponent,\n WattDrawerContentComponent,\n WattDrawerHeadingComponent,\n];\n","<!--\n@license\nCopyright 2020 Energinet DataHub A/S\n\nLicensed under the Apache License, Version 2.0 (the \"License2\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-->\n<mat-drawer-container class=\"watt-drawer-container\" [hasBackdrop]=\"false\">\n <mat-drawer\n class=\"watt-drawer watt-space-inset-s watt-drawer--{{ size() }}\"\n mode=\"side\"\n position=\"end\"\n [opened]=\"isOpen()\"\n (closed)=\"closed.emit()\"\n [disableClose]=\"true\"\n [autoFocus]=\"true\"\n [cdkTrapFocus]=\"true\"\n >\n <div class=\"watt-drawer__grid-container\">\n <header>\n <ng-content select=\"watt-drawer-topbar\" />\n <watt-button class=\"close-btn\" variant=\"icon\" icon=\"close\" (click)=\"close()\" />\n </header>\n\n <article class=\"watt-drawer__content\">\n <div class=\"watt-drawer__actions\">\n <ng-content select=\"watt-drawer-heading\" />\n <ng-content select=\"watt-drawer-actions\" />\n </div>\n <ng-content select=\"watt-drawer-content\" />\n </article>\n </div>\n\n @if (loading()) {\n <div class=\"watt-drawer__spinner\">\n <watt-spinner />\n </div>\n }\n </mat-drawer>\n</mat-drawer-container>\n","//#region License\n/**\n * @license\n * Copyright 2020 Energinet DataHub A/S\n *\n * Licensed under the Apache License, Version 2.0 (the \"License2\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n//#endregion\nexport { WattDrawerTopbarComponent } from './watt-drawer-topbar.component';\nexport { WattDrawerActionsComponent } from './watt-drawer-actions.component';\nexport { WattDrawerContentComponent } from './watt-drawer-content.component';\nexport { WattDrawerHeadingComponent } from './watt-drawer-heading.component';\nexport { WattDrawerComponent, WATT_DRAWER, WattDrawerSize } from './watt-drawer.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAAA;AACA;;;;;;;;;;;;;;;AAeG;AACH;MAQa,yBAAyB,CAAA;uGAAzB,yBAAyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAzB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,yBAAyB,8EAH1B,CAAgB,cAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,iLAAA,CAAA,EAAA,CAAA;;2FAGf,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBALrC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,oBAAoB,YACpB,CAAgB,cAAA,CAAA,EAAA,MAAA,EAAA,CAAA,iLAAA,CAAA,EAAA;;;ACtB5B;AACA;;;;;;;;;;;;;;;AAeG;AACH;MAkBa,0BAA0B,CAAA;uGAA1B,0BAA0B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAA1B,IAAA,OAAA,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