@energinet/watt 1.7.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"energinet-watt-vater.mjs","sources":["../../../libs/watt/package/vater/vater-utility.directive.ts","../../../libs/watt/package/vater/vater-flex.component.ts","../../../libs/watt/package/vater/vater-spacer.component.ts","../../../libs/watt/package/vater/vater-stack.component.ts","../../../libs/watt/package/vater/index.ts","../../../libs/watt/package/vater/energinet-watt-vater.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 { Directive, HostBinding, Input } from '@angular/core';\n\nexport type Fill = 'horizontal' | 'vertical' | 'both';\nexport type Inset = '0' | 'xs' | 's' | 'm' | 'ml' | 'l' | 'xl';\n\n/* eslint-disable @angular-eslint/no-input-rename */\n@Directive({\n selector: '[vater]',\n})\nexport class VaterUtilityDirective {\n /** Stretch the element to fill the available space in one or both directions. */\n @Input({ transform: (value: Fill) => `vater-fill-${value}` })\n fill?: Fill;\n\n /** Position the element absolute with the provided inset value. */\n @Input({ transform: (value: Inset) => `vater-inset-${value}` })\n inset?: Inset;\n\n @Input()\n center?: string;\n\n @HostBinding('class')\n get _class() {\n return [this.fill, this.inset].filter(Boolean);\n }\n\n @HostBinding('class.vater-center')\n get _center() {\n return this.center === '';\n }\n}\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, HostBinding, Input, ViewEncapsulation } from '@angular/core';\nimport { Direction, Spacing, Justify, Wrap } from './types';\nimport { VaterUtilityDirective } from './vater-utility.directive';\n\n@Component({\n selector: 'vater-flex, [vater-flex]',\n encapsulation: ViewEncapsulation.None,\n hostDirectives: [\n {\n directive: VaterUtilityDirective,\n inputs: ['center', 'fill', 'inset'],\n },\n ],\n styles: [\n `\n vater-flex,\n [vater-flex] {\n display: flex;\n line-height: normal;\n }\n\n vater-flex > *,\n [vater-flex] > * {\n flex: var(--grow) var(--shrink) var(--basis);\n }\n `,\n ],\n template: `<ng-content />`,\n})\nexport class VaterFlexComponent {\n @Input()\n @HostBinding('style.flex-direction')\n direction: Direction = 'column';\n\n @Input()\n @HostBinding('style.--grow')\n grow = '1';\n\n @Input()\n @HostBinding('style.--shrink')\n shrink = '1';\n\n @Input()\n @HostBinding('style.--basis')\n basis = 'auto';\n\n @Input()\n gap?: Spacing;\n\n @Input()\n @HostBinding('style.justify-content')\n justify?: Justify;\n\n @Input()\n @HostBinding('style.flex-wrap')\n wrap?: Wrap = 'nowrap';\n\n @Input()\n scrollable?: string;\n\n @Input()\n offset?: Spacing;\n\n @HostBinding('style.padding')\n get _offset() {\n if (!this.offset) return undefined;\n switch (this.direction) {\n case 'column':\n return `var(--watt-space-${this.offset}) 0`;\n case 'row':\n return `0 var(--watt-space-${this.offset})`;\n }\n }\n\n @HostBinding('style.gap')\n get _gap() {\n return this.gap ? `var(--watt-space-${this.gap})` : undefined;\n }\n\n @HostBinding('style.overflow')\n get _overflow() {\n return this.scrollable === '' ? 'auto' : undefined;\n }\n}\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: 'vater-spacer, [vater-spacer]',\n encapsulation: ViewEncapsulation.None,\n styles: [\n `\n vater-spacer,\n [vater-spacer] {\n flex: 1;\n align-self: stretch;\n }\n `,\n ],\n template: `<ng-content />`,\n})\nexport class VaterSpacerComponent {}\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, HostBinding, Input, ViewEncapsulation } from '@angular/core';\n\nimport { Align, Direction, Spacing, Justify } from './types';\nimport { VaterUtilityDirective } from './vater-utility.directive';\n\n@Component({\n selector: 'vater-stack, [vater-stack]',\n encapsulation: ViewEncapsulation.None,\n hostDirectives: [\n {\n directive: VaterUtilityDirective,\n inputs: ['center', 'fill', 'inset'],\n },\n ],\n styles: [\n `\n vater-stack,\n [vater-stack] {\n display: flex;\n line-height: normal;\n }\n `,\n ],\n template: `<ng-content />`,\n})\nexport class VaterStackComponent {\n @Input()\n @HostBinding('style.align-items')\n align: Align = 'center';\n\n @Input()\n @HostBinding('style.flex-direction')\n direction: Direction = 'column';\n\n @Input()\n gap?: Spacing;\n\n @Input()\n @HostBinding('style.justify-content')\n justify?: Justify;\n\n @Input()\n offset?: Spacing;\n\n @HostBinding('style.padding')\n get _offset() {\n if (!this.offset) return undefined;\n switch (this.direction) {\n case 'column':\n return `var(--watt-space-${this.offset}) 0`;\n case 'row':\n return `0 var(--watt-space-${this.offset})`;\n }\n }\n\n @HostBinding('style.gap')\n get _gap() {\n return this.gap ? `var(--watt-space-${this.gap})` : undefined;\n }\n}\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 { VaterFlexComponent } from './vater-flex.component';\nexport { VaterSpacerComponent } from './vater-spacer.component';\nexport { VaterStackComponent } from './vater-stack.component';\nexport { VaterUtilityDirective } from './vater-utility.directive';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;AAAA;AACA;;;;;;;;;;;;;;;AAeG;AACH;AAMA;MAIa,qBAAqB,CAAA;;AAGhC,IAAA,IAAI;;AAIJ,IAAA,KAAK;AAGL,IAAA,MAAM;AAEN,IAAA,IACI,MAAM,GAAA;AACR,QAAA,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC;;AAGhD,IAAA,IACI,OAAO,GAAA;AACT,QAAA,OAAO,IAAI,CAAC,MAAM,KAAK,EAAE;;uGAnBhB,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAr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A,CAAA,EAAA,QAAA,EAAA,4BAA4B,EACvB,aAAA,EAAA,iBAAiB,CAAC,IAAI,EACrB,cAAA,EAAA;AACd,wBAAA;AACE,4BAAA,SAAS,EAAE,qBAAqB;AAChC,4BAAA,MAAM,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC;AACpC,yBAAA;AACF,qBAAA,EAAA,QAAA,EAUS,CAAgB,cAAA,CAAA,EAAA,MAAA,EAAA,CAAA,8DAAA,CAAA,EAAA;8BAK1B,KAAK,EAAA,CAAA;sBAFJ;;sBACA,WAAW;uBAAC,mBAAmB;gBAKhC,SAAS,EAAA,CAAA;sBAFR;;sBACA,WAAW;uBAAC,sBAAsB;gBAInC,GAAG,EAAA,CAAA;sBADF;gBAKD,OAAO,EAAA,CAAA;sBAFN;;sBACA,WAAW;uBAAC,uBAAuB;gBAIpC,MAAM,EAAA,CAAA;sBADL;gBAIG,OAAO,EAAA,CAAA;sBADV,WAAW;uBAAC,eAAe;gBAYxB,IAAI,EAAA,CAAA;sBADP,WAAW;uBAAC,WAAW;;;ACzE1B;AACA;;;;;;;;;;;;;;;AAeG;AACH;;ACjBA;;AAEG;;;;"}
1
+ {"version":3,"file":"energinet-watt-vater.mjs","sources":["../../../libs/watt/package/vater/vater-utility.directive.ts","../../../libs/watt/package/vater/vater-layout.directive.ts","../../../libs/watt/package/vater/vater-flex.component.ts","../../../libs/watt/package/vater/vater-spacer.component.ts","../../../libs/watt/package/vater/vater-stack.component.ts","../../../libs/watt/package/vater/index.ts","../../../libs/watt/package/vater/energinet-watt-vater.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 { booleanAttribute, computed, Directive, input } from '@angular/core';\nimport { Fill, Inset } from './types';\n\n/* eslint-disable @angular-eslint/no-input-rename */\n@Directive({\n selector: '[vater]',\n host: {\n '[class]': 'class()',\n '[class.vater-center]': 'center()',\n '[class.vater-scrollable]': 'scrollable()',\n },\n})\nexport class VaterUtilityDirective {\n /** Center the element horizontally and vertically. */\n center = input(false, { transform: booleanAttribute });\n\n /** Stretch the element to fill the available space in one or both directions. */\n fill = input<Fill>();\n\n /** Position the element absolute with the provided inset value. */\n inset = input<Inset>();\n\n /** Make the element scrollable. */\n scrollable = input(false, { transform: booleanAttribute });\n\n // Computed class names\n protected fillClass = computed(() => this.fill() && `vater-fill-${this.fill()}`);\n protected insetClass = computed(() => this.inset() && `vater-inset-${this.inset()}`);\n protected class = computed(() => [this.fillClass(), this.insetClass()].filter(Boolean));\n}\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 { booleanAttribute, computed, Directive, input } from '@angular/core';\nimport { Align, Direction, Justify, Spacing } from './types';\n\n@Directive({\n host: {\n '[class]': 'class()',\n '[class.vater-wrap]': 'wrap()',\n },\n})\nexport class VaterLayoutDirective {\n /** Cross axis alignment of the flex items. */\n align = input<Align>();\n\n /** Direction of the flex items. Defaults to `column`. */\n direction = input<Direction>('column');\n\n /** Spacing between the flex items. */\n gap = input<Spacing>();\n\n /** Main axis alignment of the flex items. */\n justify = input<Justify>();\n\n /** Offset to apply along the main axis. */\n offset = input<Spacing>();\n\n /** Whether the flex items should wrap. */\n wrap = input(false, { transform: booleanAttribute });\n\n // Computed class names\n protected alignClass = computed(() => this.align() && `vater-align-${this.align()}`);\n protected directionClass = computed(() => this.direction() && `vater-${this.direction()}`);\n protected gapClass = computed(() => this.gap() && `vater-gap-${this.gap()}`);\n protected justifyClass = computed(() => this.justify() && `vater-justify-${this.justify()}`);\n protected offsetClass = computed(() => this.offset() && `vater-offset-${this.offset()}`);\n protected class = computed(() =>\n [\n this.alignClass(),\n this.directionClass(),\n this.gapClass(),\n this.justifyClass(),\n this.offsetClass(),\n ].filter(Boolean)\n );\n}\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 { booleanAttribute, Component, input, ViewEncapsulation } from '@angular/core';\nimport { VaterUtilityDirective } from './vater-utility.directive';\nimport { VaterLayoutDirective } from './vater-layout.directive';\n\n@Component({\n selector: 'vater-flex, [vater-flex]',\n encapsulation: ViewEncapsulation.None,\n hostDirectives: [\n {\n directive: VaterLayoutDirective,\n inputs: ['align', 'direction', 'justify', 'wrap', 'gap', 'offset'],\n },\n {\n directive: VaterUtilityDirective,\n inputs: ['center', 'fill', 'inset', 'scrollable'],\n },\n ],\n host: { '[class.vater-flex-auto]': 'autoSize()' },\n styles: `\n vater-flex,\n [vater-flex] {\n display: flex;\n line-height: normal;\n }\n `,\n template: `<ng-content />`,\n})\nexport class VaterFlexComponent {\n /**\n * When set, sizes the flex items according to their width or height properties.\n * @see https://drafts.csswg.org/css-flexbox-1/#flex-common\n * @remarks\n * Prefer setting `fill` on flex items over using `autoSize`.\n */\n autoSize = input(false, { transform: booleanAttribute });\n}\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: 'vater-spacer, [vater-spacer]',\n encapsulation: ViewEncapsulation.None,\n styles: `\n vater-spacer,\n [vater-spacer] {\n flex: 1;\n align-self: stretch;\n }\n `,\n template: '<ng-content />',\n})\nexport class VaterSpacerComponent {}\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';\nimport { VaterUtilityDirective } from './vater-utility.directive';\nimport { VaterLayoutDirective } from './vater-layout.directive';\n\n@Component({\n selector: 'vater-stack, [vater-stack]',\n encapsulation: ViewEncapsulation.None,\n hostDirectives: [\n {\n directive: VaterLayoutDirective,\n inputs: ['align', 'direction', 'justify', 'wrap', 'gap', 'offset'],\n },\n {\n directive: VaterUtilityDirective,\n inputs: ['center', 'fill', 'inset', 'scrollable'],\n },\n ],\n styles: `\n vater-stack,\n [vater-stack] {\n display: flex;\n line-height: normal;\n }\n `,\n template: `<ng-content />`,\n})\nexport class VaterStackComponent {}\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 { VaterFlexComponent } from './vater-flex.component';\nexport { VaterSpacerComponent } from './vater-spacer.component';\nexport { VaterStackComponent } from './vater-stack.component';\nexport { VaterLayoutDirective } from './vater-layout.directive';\nexport { VaterUtilityDirective } from './vater-utility.directive';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;AAAA;AACA;;;;;;;;;;;;;;;AAeG;AACH;AAIA;MASa,qBAAqB,CAAA;;IAEhC,MAAM,GAAG,KAAK,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;;IAGtD,IAAI,GAAG,KAAK,EAAQ;;IAGpB,KAAK,GAAG,KAAK,EAAS;;IAGtB,UAAU,GAAG,KAAK,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;;AAGhD,IAAA,SAAS,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,IAAI,cAAc,IAAI,CAAC,IAAI,EAAE,CAAA,CAAE,CAAC;AACtE,IAAA,UAAU,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,KAAK,EAAE,IAAI,eAAe,IAAI,CAAC,KAAK,EAAE,CAAA,CAAE,CAAC;IAC1E,KAAK,GAAG,QAAQ,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,EAAE,IAAI,CAAC,UAAU,EAAE,CAA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AA,EAAA,iBAAiB,CAAC,IAAI,EACrB,cAAA,EAAA;AACd,wBAAA;AACE,4BAAA,SAAS,EAAE,oBAAoB;AAC/B,4BAAA,MAAM,EAAE,CAAC,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,CAAC;AACnE,yBAAA;AACD,wBAAA;AACE,4BAAA,SAAS,EAAE,qBAAqB;4BAChC,MAAM,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,YAAY,CAAC;AAClD,yBAAA;AACF,qBAAA,EAAA,QAAA,EAQS,CAAgB,cAAA,CAAA,EAAA,MAAA,EAAA,CAAA,8DAAA,CAAA,EAAA;;;AC1C5B;AACA;;;;;;;;;;;;;;;AAeG;AACH;;ACjBA;;AAEG;;;;"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@energinet/watt",
4
- "version": "1.7.0",
4
+ "version": "2.0.0",
5
5
  "license": "Apache-2.0",
6
6
  "exports": {
7
7
  ".": {
package/vater/index.d.ts CHANGED
@@ -17,4 +17,5 @@
17
17
  export { VaterFlexComponent } from './vater-flex.component';
18
18
  export { VaterSpacerComponent } from './vater-spacer.component';
19
19
  export { VaterStackComponent } from './vater-stack.component';
20
+ export { VaterLayoutDirective } from './vater-layout.directive';
20
21
  export { VaterUtilityDirective } from './vater-utility.directive';
package/vater/types.d.ts CHANGED
@@ -14,8 +14,9 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- export type Direction = 'row' | 'column';
18
- export type Justify = 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly';
19
- export type Align = 'stretch' | 'flex-start' | 'flex-end' | 'center' | 'baseline';
20
- export type Wrap = 'nowrap' | 'wrap' | 'wrap-reverse';
21
17
  export type Spacing = 'xs' | 's' | 'm' | 'ml' | 'l' | 'xl';
18
+ export type Fill = 'horizontal' | 'vertical' | 'both';
19
+ export type Inset = '0' | Spacing;
20
+ export type Align = 'stretch' | 'start' | 'end' | 'center' | 'baseline';
21
+ export type Direction = 'row' | 'column';
22
+ export type Justify = 'start' | 'end' | 'center' | 'space-between' | 'space-around' | 'space-evenly';
@@ -1,19 +1,14 @@
1
- import { Direction, Spacing, Justify, Wrap } from './types';
2
1
  import * as i0 from "@angular/core";
3
- import * as i1 from "./vater-utility.directive";
2
+ import * as i1 from "./vater-layout.directive";
3
+ import * as i2 from "./vater-utility.directive";
4
4
  export declare class VaterFlexComponent {
5
- direction: Direction;
6
- grow: string;
7
- shrink: string;
8
- basis: string;
9
- gap?: Spacing;
10
- justify?: Justify;
11
- wrap?: Wrap;
12
- scrollable?: string;
13
- offset?: Spacing;
14
- get _offset(): string | undefined;
15
- get _gap(): string | undefined;
16
- get _overflow(): "auto" | undefined;
5
+ /**
6
+ * When set, sizes the flex items according to their width or height properties.
7
+ * @see https://drafts.csswg.org/css-flexbox-1/#flex-common
8
+ * @remarks
9
+ * Prefer setting `fill` on flex items over using `autoSize`.
10
+ */
11
+ autoSize: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
17
12
  static ɵfac: i0.ɵɵFactoryDeclaration<VaterFlexComponent, never>;
18
- static ɵcmp: i0.ɵɵComponentDeclaration<VaterFlexComponent, "vater-flex, [vater-flex]", never, { "direction": { "alias": "direction"; "required": false; }; "grow": { "alias": "grow"; "required": false; }; "shrink": { "alias": "shrink"; "required": false; }; "basis": { "alias": "basis"; "required": false; }; "gap": { "alias": "gap"; "required": false; }; "justify": { "alias": "justify"; "required": false; }; "wrap": { "alias": "wrap"; "required": false; }; "scrollable": { "alias": "scrollable"; "required": false; }; "offset": { "alias": "offset"; "required": false; }; }, {}, never, ["*"], true, [{ directive: typeof i1.VaterUtilityDirective; inputs: { "center": "center"; "fill": "fill"; "inset": "inset"; }; outputs: {}; }]>;
13
+ static ɵcmp: i0.ɵɵComponentDeclaration<VaterFlexComponent, "vater-flex, [vater-flex]", never, { "autoSize": { "alias": "autoSize"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, [{ directive: typeof i1.VaterLayoutDirective; inputs: { "align": "align"; "direction": "direction"; "justify": "justify"; "wrap": "wrap"; "gap": "gap"; "offset": "offset"; }; outputs: {}; }, { directive: typeof i2.VaterUtilityDirective; inputs: { "center": "center"; "fill": "fill"; "inset": "inset"; "scrollable": "scrollable"; }; outputs: {}; }]>;
19
14
  }
@@ -0,0 +1,24 @@
1
+ import { Align, Direction, Justify, Spacing } from './types';
2
+ import * as i0 from "@angular/core";
3
+ export declare class VaterLayoutDirective {
4
+ /** Cross axis alignment of the flex items. */
5
+ align: import("@angular/core").InputSignal<Align | undefined>;
6
+ /** Direction of the flex items. Defaults to `column`. */
7
+ direction: import("@angular/core").InputSignal<Direction>;
8
+ /** Spacing between the flex items. */
9
+ gap: import("@angular/core").InputSignal<Spacing | undefined>;
10
+ /** Main axis alignment of the flex items. */
11
+ justify: import("@angular/core").InputSignal<Justify | undefined>;
12
+ /** Offset to apply along the main axis. */
13
+ offset: import("@angular/core").InputSignal<Spacing | undefined>;
14
+ /** Whether the flex items should wrap. */
15
+ wrap: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
16
+ protected alignClass: import("@angular/core").Signal<string | undefined>;
17
+ protected directionClass: import("@angular/core").Signal<string>;
18
+ protected gapClass: import("@angular/core").Signal<string | undefined>;
19
+ protected justifyClass: import("@angular/core").Signal<string | undefined>;
20
+ protected offsetClass: import("@angular/core").Signal<string | undefined>;
21
+ protected class: import("@angular/core").Signal<(string | undefined)[]>;
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<VaterLayoutDirective, never>;
23
+ static ɵdir: i0.ɵɵDirectiveDeclaration<VaterLayoutDirective, never, never, { "align": { "alias": "align"; "required": false; "isSignal": true; }; "direction": { "alias": "direction"; "required": false; "isSignal": true; }; "gap": { "alias": "gap"; "required": false; "isSignal": true; }; "justify": { "alias": "justify"; "required": false; "isSignal": true; }; "offset": { "alias": "offset"; "required": false; "isSignal": true; }; "wrap": { "alias": "wrap"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
24
+ }
@@ -1,14 +1,7 @@
1
- import { Align, Direction, Spacing, Justify } from './types';
2
1
  import * as i0 from "@angular/core";
3
- import * as i1 from "./vater-utility.directive";
2
+ import * as i1 from "./vater-layout.directive";
3
+ import * as i2 from "./vater-utility.directive";
4
4
  export declare class VaterStackComponent {
5
- align: Align;
6
- direction: Direction;
7
- gap?: Spacing;
8
- justify?: Justify;
9
- offset?: Spacing;
10
- get _offset(): string | undefined;
11
- get _gap(): string | undefined;
12
5
  static ɵfac: i0.ɵɵFactoryDeclaration<VaterStackComponent, never>;
13
- static ɵcmp: i0.ɵɵComponentDeclaration<VaterStackComponent, "vater-stack, [vater-stack]", never, { "align": { "alias": "align"; "required": false; }; "direction": { "alias": "direction"; "required": false; }; "gap": { "alias": "gap"; "required": false; }; "justify": { "alias": "justify"; "required": false; }; "offset": { "alias": "offset"; "required": false; }; }, {}, never, ["*"], true, [{ directive: typeof i1.VaterUtilityDirective; inputs: { "center": "center"; "fill": "fill"; "inset": "inset"; }; outputs: {}; }]>;
6
+ static ɵcmp: i0.ɵɵComponentDeclaration<VaterStackComponent, "vater-stack, [vater-stack]", never, {}, {}, never, ["*"], true, [{ directive: typeof i1.VaterLayoutDirective; inputs: { "align": "align"; "direction": "direction"; "justify": "justify"; "wrap": "wrap"; "gap": "gap"; "offset": "offset"; }; outputs: {}; }, { directive: typeof i2.VaterUtilityDirective; inputs: { "center": "center"; "fill": "fill"; "inset": "inset"; "scrollable": "scrollable"; }; outputs: {}; }]>;
14
7
  }
@@ -1,16 +1,17 @@
1
+ import { Fill, Inset } from './types';
1
2
  import * as i0 from "@angular/core";
2
- export type Fill = 'horizontal' | 'vertical' | 'both';
3
- export type Inset = '0' | 'xs' | 's' | 'm' | 'ml' | 'l' | 'xl';
4
3
  export declare class VaterUtilityDirective {
4
+ /** Center the element horizontally and vertically. */
5
+ center: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
5
6
  /** Stretch the element to fill the available space in one or both directions. */
6
- fill?: Fill;
7
+ fill: import("@angular/core").InputSignal<Fill | undefined>;
7
8
  /** Position the element absolute with the provided inset value. */
8
- inset?: Inset;
9
- center?: string;
10
- get _class(): (Fill | Inset | undefined)[];
11
- get _center(): boolean;
9
+ inset: import("@angular/core").InputSignal<Inset | undefined>;
10
+ /** Make the element scrollable. */
11
+ scrollable: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
12
+ protected fillClass: import("@angular/core").Signal<string | undefined>;
13
+ protected insetClass: import("@angular/core").Signal<string | undefined>;
14
+ protected class: import("@angular/core").Signal<(string | undefined)[]>;
12
15
  static ɵfac: i0.ɵɵFactoryDeclaration<VaterUtilityDirective, never>;
13
- static ɵdir: i0.ɵɵDirectiveDeclaration<VaterUtilityDirective, "[vater]", never, { "fill": { "alias": "fill"; "required": false; }; "inset": { "alias": "inset"; "required": false; }; "center": { "alias": "center"; "required": false; }; }, {}, never, never, true, never>;
14
- static ngAcceptInputType_fill: Fill;
15
- static ngAcceptInputType_inset: Inset;
16
+ static ɵdir: i0.ɵɵDirectiveDeclaration<VaterUtilityDirective, "[vater]", never, { "center": { "alias": "center"; "required": false; "isSignal": true; }; "fill": { "alias": "fill"; "required": false; "isSignal": true; }; "inset": { "alias": "inset"; "required": false; "isSignal": true; }; "scrollable": { "alias": "scrollable"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
16
17
  }