@qualcomm-ui/angular 1.0.0 → 1.0.2
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.
- package/README.md +9 -0
- package/avatar/avatar-content.directive.d.ts +1 -6
- package/avatar/avatar-content.directive.d.ts.map +1 -1
- package/combobox/combobox-trigger.directive.d.ts +1 -0
- package/combobox/combobox-trigger.directive.d.ts.map +1 -1
- package/esm2022/avatar/avatar-content.directive.js +3 -8
- package/esm2022/avatar/avatar-content.directive.js.map +1 -1
- package/esm2022/combobox/combobox-trigger.directive.js +18 -4
- package/esm2022/combobox/combobox-trigger.directive.js.map +1 -1
- package/esm2022/select/select-indicator.directive.js +13 -3
- package/esm2022/select/select-indicator.directive.js.map +1 -1
- package/esm2022/select/select.component.js +2 -2
- package/esm2022/select/select.component.js.map +1 -1
- package/package.json +10 -9
- package/select/select-indicator.directive.d.ts +8 -2
- package/select/select-indicator.directive.d.ts.map +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# @qualcomm-ui/angular
|
|
2
|
+
|
|
3
|
+
QUI Angular components implementing the Qualcomm Design System.
|
|
4
|
+
|
|
5
|
+
For comprehensive documentation, examples, and usage guides, visit the [Angular documentation](https://angular-next.qui.qualcomm.com/).
|
|
6
|
+
|
|
7
|
+
## License
|
|
8
|
+
|
|
9
|
+
Licensed under the [BSD-3-Clause-Clear License](https://spdx.org/licenses/BSD-3-Clause-Clear.html).
|
|
@@ -1,14 +1,9 @@
|
|
|
1
1
|
import { CoreAvatarContentDirective } from "@qualcomm-ui/angular-core/avatar";
|
|
2
|
-
import { type QdsAvatarVariant } from "@qualcomm-ui/qds-core/avatar";
|
|
3
2
|
import * as i0 from "@angular/core";
|
|
4
3
|
export declare class AvatarContentDirective extends CoreAvatarContentDirective {
|
|
5
|
-
/**
|
|
6
|
-
* The variant of the avatar.
|
|
7
|
-
*/
|
|
8
|
-
readonly variant: import("@angular/core").InputSignal<QdsAvatarVariant | undefined>;
|
|
9
4
|
readonly qdsContext: () => import("@qualcomm-ui/qds-core/avatar").QdsAvatarApi;
|
|
10
5
|
constructor();
|
|
11
6
|
static ɵfac: i0.ɵɵFactoryDeclaration<AvatarContentDirective, never>;
|
|
12
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<AvatarContentDirective, "[q-avatar-content]", never, {
|
|
7
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<AvatarContentDirective, "[q-avatar-content]", never, {}, {}, never, never, false, never>;
|
|
13
8
|
}
|
|
14
9
|
//# sourceMappingURL=avatar-content.directive.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"avatar-content.directive.d.ts","sourceRoot":"","sources":["../../../src/avatar/avatar-content.directive.ts"],"names":[],"mappings":"AAKA,OAAO,EAAC,0BAA0B,EAAC,MAAM,kCAAkC,CAAA
|
|
1
|
+
{"version":3,"file":"avatar-content.directive.d.ts","sourceRoot":"","sources":["../../../src/avatar/avatar-content.directive.ts"],"names":[],"mappings":"AAKA,OAAO,EAAC,0BAA0B,EAAC,MAAM,kCAAkC,CAAA;;AAI3E,qBAIa,sBAAuB,SAAQ,0BAA0B;IACpE,QAAQ,CAAC,UAAU,4DAAwB;;yCADhC,sBAAsB;2CAAtB,sBAAsB;CASlC"}
|
|
@@ -2,6 +2,7 @@ import { CoreComboboxTriggerDirective } from "@qualcomm-ui/angular-core/combobox
|
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class ComboboxTriggerDirective extends CoreComboboxTriggerDirective {
|
|
4
4
|
protected readonly qdsComboboxContext: () => import("@qualcomm-ui/qds-core/select").QdsSelectApi;
|
|
5
|
+
protected readonly inlineIconButtonApi: import("@angular/core").Signal<import("@qualcomm-ui/qds-core/inline-icon-button").QdsInlineIconButtonApi>;
|
|
5
6
|
constructor();
|
|
6
7
|
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxTriggerDirective, never>;
|
|
7
8
|
static ɵcmp: i0.ɵɵComponentDeclaration<ComboboxTriggerDirective, "[q-combobox-trigger]", never, {}, {}, never, ["*"], false, never>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox-trigger.directive.d.ts","sourceRoot":"","sources":["../../../src/combobox/combobox-trigger.directive.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"combobox-trigger.directive.d.ts","sourceRoot":"","sources":["../../../src/combobox/combobox-trigger.directive.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,4BAA4B,EAAC,MAAM,oCAAoC,CAAA;;AAM/E,qBAaa,wBAAyB,SAAQ,4BAA4B;IACxE,SAAS,CAAC,QAAQ,CAAC,kBAAkB,4DAA0B;IAC/D,SAAS,CAAC,QAAQ,CAAC,mBAAmB,4GAMpC;;yCARS,wBAAwB;2CAAxB,wBAAwB;CAqBpC"}
|
|
@@ -1,22 +1,17 @@
|
|
|
1
1
|
// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
|
|
2
2
|
// SPDX-License-Identifier: BSD-3-Clause-Clear
|
|
3
|
-
import { computed, Directive
|
|
3
|
+
import { computed, Directive } from "@angular/core";
|
|
4
4
|
import { CoreAvatarContentDirective } from "@qualcomm-ui/angular-core/avatar";
|
|
5
|
-
import {} from "@qualcomm-ui/qds-core/avatar";
|
|
6
5
|
import { useQdsAvatarContext } from "./qds-avatar-context.service";
|
|
7
6
|
import * as i0 from "@angular/core";
|
|
8
7
|
export class AvatarContentDirective extends CoreAvatarContentDirective {
|
|
9
|
-
/**
|
|
10
|
-
* The variant of the avatar.
|
|
11
|
-
*/
|
|
12
|
-
variant = input(...(ngDevMode ? [undefined, { debugName: "variant" }] : []));
|
|
13
8
|
qdsContext = useQdsAvatarContext();
|
|
14
9
|
constructor() {
|
|
15
10
|
super();
|
|
16
11
|
this.trackBindings.extendWith(computed(() => this.qdsContext().getContentBindings()));
|
|
17
12
|
}
|
|
18
13
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: AvatarContentDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
19
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "
|
|
14
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.10", type: AvatarContentDirective, isStandalone: false, selector: "[q-avatar-content]", usesInheritance: true, ngImport: i0 });
|
|
20
15
|
}
|
|
21
16
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: AvatarContentDirective, decorators: [{
|
|
22
17
|
type: Directive,
|
|
@@ -24,5 +19,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImpo
|
|
|
24
19
|
selector: "[q-avatar-content]",
|
|
25
20
|
standalone: false,
|
|
26
21
|
}]
|
|
27
|
-
}], ctorParameters: () => []
|
|
22
|
+
}], ctorParameters: () => [] });
|
|
28
23
|
//# sourceMappingURL=avatar-content.directive.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"avatar-content.directive.js","sourceRoot":"","sources":["../../../src/avatar/avatar-content.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,QAAQ,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"avatar-content.directive.js","sourceRoot":"","sources":["../../../src/avatar/avatar-content.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,QAAQ,EAAE,SAAS,EAAC,MAAM,eAAe,CAAA;AAEjD,OAAO,EAAC,0BAA0B,EAAC,MAAM,kCAAkC,CAAA;AAE3E,OAAO,EAAC,mBAAmB,EAAC,MAAM,8BAA8B,CAAA;;AAMhE,MAAM,OAAO,sBAAuB,SAAQ,0BAA0B;IAC3D,UAAU,GAAG,mBAAmB,EAAE,CAAA;IAE3C;QACE,KAAK,EAAE,CAAA;QACP,IAAI,CAAC,aAAa,CAAC,UAAU,CAC3B,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC,kBAAkB,EAAE,CAAC,CACvD,CAAA;IACH,CAAC;wGARU,sBAAsB;4FAAtB,sBAAsB;;4FAAtB,sBAAsB;kBAJlC,SAAS;mBAAC;oBACT,QAAQ,EAAE,oBAAoB;oBAC9B,UAAU,EAAE,KAAK;iBAClB","sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreAvatarContentDirective} from \"@qualcomm-ui/angular-core/avatar\"\n\nimport {useQdsAvatarContext} from \"./qds-avatar-context.service\"\n\n@Directive({\n selector: \"[q-avatar-content]\",\n standalone: false,\n})\nexport class AvatarContentDirective extends CoreAvatarContentDirective {\n readonly qdsContext = useQdsAvatarContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsContext().getContentBindings()),\n )\n }\n}\n"]}
|
|
@@ -2,23 +2,34 @@
|
|
|
2
2
|
// SPDX-License-Identifier: BSD-3-Clause-Clear
|
|
3
3
|
import { Component, computed } from "@angular/core";
|
|
4
4
|
import { ChevronDown } from "lucide-angular";
|
|
5
|
+
import { useInlineIconButtonApi } from "@qualcomm-ui/angular/inline-icon-button";
|
|
5
6
|
import { CoreComboboxTriggerDirective } from "@qualcomm-ui/angular-core/combobox";
|
|
6
7
|
import { provideIcons } from "@qualcomm-ui/angular-core/lucide";
|
|
8
|
+
import { mergeProps } from "@qualcomm-ui/utils/merge-props";
|
|
7
9
|
import { useQdsComboboxContext } from "./qds-combobox-context.service";
|
|
8
10
|
import * as i0 from "@angular/core";
|
|
9
11
|
import * as i1 from "@qualcomm-ui/angular/icon";
|
|
12
|
+
import * as i2 from "@qualcomm-ui/angular-core/machine";
|
|
10
13
|
export class ComboboxTriggerDirective extends CoreComboboxTriggerDirective {
|
|
11
14
|
qdsComboboxContext = useQdsComboboxContext();
|
|
15
|
+
inlineIconButtonApi = useInlineIconButtonApi({
|
|
16
|
+
emphasis: "neutral",
|
|
17
|
+
size: computed(() => this.qdsComboboxContext().size === "sm" ? "sm" : "md"),
|
|
18
|
+
variant: "scale",
|
|
19
|
+
});
|
|
12
20
|
constructor() {
|
|
13
21
|
super();
|
|
14
|
-
this.trackBindings.extendWith(computed(() => this.qdsComboboxContext().getIndicatorBindings()));
|
|
22
|
+
this.trackBindings.extendWith(computed(() => mergeProps(this.qdsComboboxContext().getIndicatorBindings(), this.inlineIconButtonApi().getRootBindings())));
|
|
15
23
|
}
|
|
16
24
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: ComboboxTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
17
25
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.10", type: ComboboxTriggerDirective, isStandalone: false, selector: "[q-combobox-trigger]", providers: [provideIcons({ ChevronDown })], usesInheritance: true, ngImport: i0, template: `
|
|
18
26
|
<ng-content>
|
|
19
|
-
<svg
|
|
27
|
+
<svg
|
|
28
|
+
qIcon="ChevronDown"
|
|
29
|
+
[q-bind]="inlineIconButtonApi().getIconBindings()"
|
|
30
|
+
></svg>
|
|
20
31
|
</ng-content>
|
|
21
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i1.IconDirective, selector: "svg[qIcon]", inputs: ["qIcon", "size", "viewBox", "xmlns", "height", "width"] }] });
|
|
32
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.IconDirective, selector: "svg[qIcon]", inputs: ["qIcon", "size", "viewBox", "xmlns", "height", "width"] }, { kind: "directive", type: i2.QBindDirective, selector: "[q-bind]", inputs: ["q-bind", "q-bind-options"] }] });
|
|
22
33
|
}
|
|
23
34
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: ComboboxTriggerDirective, decorators: [{
|
|
24
35
|
type: Component,
|
|
@@ -28,7 +39,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImpo
|
|
|
28
39
|
standalone: false,
|
|
29
40
|
template: `
|
|
30
41
|
<ng-content>
|
|
31
|
-
<svg
|
|
42
|
+
<svg
|
|
43
|
+
qIcon="ChevronDown"
|
|
44
|
+
[q-bind]="inlineIconButtonApi().getIconBindings()"
|
|
45
|
+
></svg>
|
|
32
46
|
</ng-content>
|
|
33
47
|
`,
|
|
34
48
|
}]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox-trigger.directive.js","sourceRoot":"","sources":["../../../src/combobox/combobox-trigger.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,eAAe,CAAA;AACjD,OAAO,EAAC,WAAW,EAAC,MAAM,gBAAgB,CAAA;AAE1C,OAAO,EAAC,4BAA4B,EAAC,MAAM,oCAAoC,CAAA;AAC/E,OAAO,EAAC,YAAY,EAAC,MAAM,kCAAkC,CAAA;
|
|
1
|
+
{"version":3,"file":"combobox-trigger.directive.js","sourceRoot":"","sources":["../../../src/combobox/combobox-trigger.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,eAAe,CAAA;AACjD,OAAO,EAAC,WAAW,EAAC,MAAM,gBAAgB,CAAA;AAE1C,OAAO,EAAC,sBAAsB,EAAC,MAAM,yCAAyC,CAAA;AAC9E,OAAO,EAAC,4BAA4B,EAAC,MAAM,oCAAoC,CAAA;AAC/E,OAAO,EAAC,YAAY,EAAC,MAAM,kCAAkC,CAAA;AAC7D,OAAO,EAAC,UAAU,EAAC,MAAM,gCAAgC,CAAA;AAEzD,OAAO,EAAC,qBAAqB,EAAC,MAAM,gCAAgC,CAAA;;;;AAepE,MAAM,OAAO,wBAAyB,SAAQ,4BAA4B;IACrD,kBAAkB,GAAG,qBAAqB,EAAE,CAAA;IAC5C,mBAAmB,GAAG,sBAAsB,CAAC;QAC9D,QAAQ,EAAE,SAAS;QACnB,IAAI,EAAE,QAAQ,CAAC,GAAG,EAAE,CAClB,IAAI,CAAC,kBAAkB,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CACtD;QACD,OAAO,EAAE,OAAO;KACjB,CAAC,CAAA;IAEF;QACE,KAAK,EAAE,CAAA;QACP,IAAI,CAAC,aAAa,CAAC,UAAU,CAC3B,QAAQ,CAAC,GAAG,EAAE,CACZ,UAAU,CACR,IAAI,CAAC,kBAAkB,EAAE,CAAC,oBAAoB,EAAE,EAChD,IAAI,CAAC,mBAAmB,EAAE,CAAC,eAAe,EAAE,CAC7C,CACF,CACF,CAAA;IACH,CAAC;wGApBU,wBAAwB;4FAAxB,wBAAwB,oEAZxB,CAAC,YAAY,CAAC,EAAC,WAAW,EAAC,CAAC,CAAC,iDAG9B;;;;;;;GAOT;;4FAEU,wBAAwB;kBAbpC,SAAS;mBAAC;oBACT,SAAS,EAAE,CAAC,YAAY,CAAC,EAAC,WAAW,EAAC,CAAC,CAAC;oBACxC,QAAQ,EAAE,sBAAsB;oBAChC,UAAU,EAAE,KAAK;oBACjB,QAAQ,EAAE;;;;;;;GAOT;iBACF","sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed} from \"@angular/core\"\nimport {ChevronDown} from \"lucide-angular\"\n\nimport {useInlineIconButtonApi} from \"@qualcomm-ui/angular/inline-icon-button\"\nimport {CoreComboboxTriggerDirective} from \"@qualcomm-ui/angular-core/combobox\"\nimport {provideIcons} from \"@qualcomm-ui/angular-core/lucide\"\nimport {mergeProps} from \"@qualcomm-ui/utils/merge-props\"\n\nimport {useQdsComboboxContext} from \"./qds-combobox-context.service\"\n\n@Component({\n providers: [provideIcons({ChevronDown})],\n selector: \"[q-combobox-trigger]\",\n standalone: false,\n template: `\n <ng-content>\n <svg\n qIcon=\"ChevronDown\"\n [q-bind]=\"inlineIconButtonApi().getIconBindings()\"\n ></svg>\n </ng-content>\n `,\n})\nexport class ComboboxTriggerDirective extends CoreComboboxTriggerDirective {\n protected readonly qdsComboboxContext = useQdsComboboxContext()\n protected readonly inlineIconButtonApi = useInlineIconButtonApi({\n emphasis: \"neutral\",\n size: computed(() =>\n this.qdsComboboxContext().size === \"sm\" ? \"sm\" : \"md\",\n ),\n variant: \"scale\",\n })\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() =>\n mergeProps(\n this.qdsComboboxContext().getIndicatorBindings(),\n this.inlineIconButtonApi().getRootBindings(),\n ),\n ),\n )\n }\n}\n"]}
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
// SPDX-License-Identifier: BSD-3-Clause-Clear
|
|
3
3
|
import { Component, computed, input } from "@angular/core";
|
|
4
4
|
import { ChevronDown } from "lucide-angular";
|
|
5
|
+
import { useInlineIconButtonApi } from "@qualcomm-ui/angular/inline-icon-button";
|
|
6
|
+
import { useTrackBindings } from "@qualcomm-ui/angular-core/machine";
|
|
5
7
|
import { useSelectContext } from "@qualcomm-ui/angular-core/select";
|
|
6
8
|
import { mergeProps } from "@qualcomm-ui/utils/merge-props";
|
|
7
9
|
import { useQdsSelectContext } from "./qds-select-context.service";
|
|
@@ -17,10 +19,18 @@ export class SelectIndicatorDirective {
|
|
|
17
19
|
icon = input(ChevronDown, ...(ngDevMode ? [{ debugName: "icon" }] : []));
|
|
18
20
|
qdsSelectContext = useQdsSelectContext();
|
|
19
21
|
selectContext = useSelectContext();
|
|
20
|
-
|
|
22
|
+
inlineIconButtonApi = useInlineIconButtonApi({
|
|
23
|
+
emphasis: "neutral",
|
|
24
|
+
size: computed(() => (this.qdsSelectContext().size === "sm" ? "sm" : "md")),
|
|
25
|
+
variant: "scale",
|
|
26
|
+
});
|
|
27
|
+
trackBindings = useTrackBindings(() => mergeProps(this.selectContext().getIndicatorBindings(), this.qdsSelectContext().getIndicatorBindings(), this.inlineIconButtonApi().getRootBindings()));
|
|
28
|
+
ngOnInit() {
|
|
29
|
+
this.trackBindings();
|
|
30
|
+
}
|
|
21
31
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: SelectIndicatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
22
32
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.10", type: SelectIndicatorDirective, isStandalone: false, selector: "[q-select-indicator]", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `
|
|
23
|
-
<svg [q-bind]="
|
|
33
|
+
<svg [q-bind]="inlineIconButtonApi().getIconBindings()" [qIcon]="icon()" />
|
|
24
34
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.IconDirective, selector: "svg[qIcon]", inputs: ["qIcon", "size", "viewBox", "xmlns", "height", "width"] }, { kind: "directive", type: i2.QBindDirective, selector: "[q-bind]", inputs: ["q-bind", "q-bind-options"] }] });
|
|
25
35
|
}
|
|
26
36
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImport: i0, type: SelectIndicatorDirective, decorators: [{
|
|
@@ -29,7 +39,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImpo
|
|
|
29
39
|
selector: "[q-select-indicator]",
|
|
30
40
|
standalone: false,
|
|
31
41
|
template: `
|
|
32
|
-
<svg [q-bind]="
|
|
42
|
+
<svg [q-bind]="inlineIconButtonApi().getIconBindings()" [qIcon]="icon()" />
|
|
33
43
|
`,
|
|
34
44
|
}]
|
|
35
45
|
}], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }] } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-indicator.directive.js","sourceRoot":"","sources":["../../../src/select/select-indicator.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAE,KAAK,
|
|
1
|
+
{"version":3,"file":"select-indicator.directive.js","sourceRoot":"","sources":["../../../src/select/select-indicator.directive.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAc,MAAM,eAAe,CAAA;AACrE,OAAO,EAAC,WAAW,EAAC,MAAM,gBAAgB,CAAA;AAE1C,OAAO,EAAC,sBAAsB,EAAC,MAAM,yCAAyC,CAAA;AAE9E,OAAO,EAAC,gBAAgB,EAAC,MAAM,mCAAmC,CAAA;AAClE,OAAO,EAAC,gBAAgB,EAAC,MAAM,kCAAkC,CAAA;AACjE,OAAO,EAAC,UAAU,EAAC,MAAM,gCAAgC,CAAA;AAEzD,OAAO,EAAC,mBAAmB,EAAC,MAAM,8BAA8B,CAAA;;;;AAShE,MAAM,OAAO,wBAAwB;IACnC;;;;OAIG;IACM,IAAI,GAAG,KAAK,CAAqB,WAAW,gDAAC,CAAA;IAEnC,gBAAgB,GAAG,mBAAmB,EAAE,CAAA;IACxC,aAAa,GAAG,gBAAgB,EAAE,CAAA;IAClC,mBAAmB,GAAG,sBAAsB,CAAC;QAC9D,QAAQ,EAAE,SAAS;QACnB,IAAI,EAAE,QAAQ,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;QAC3E,OAAO,EAAE,OAAO;KACjB,CAAC,CAAA;IAEiB,aAAa,GAAG,gBAAgB,CAAC,GAAG,EAAE,CACvD,UAAU,CACR,IAAI,CAAC,aAAa,EAAE,CAAC,oBAAoB,EAAE,EAC3C,IAAI,CAAC,gBAAgB,EAAE,CAAC,oBAAoB,EAAE,EAC9C,IAAI,CAAC,mBAAmB,EAAE,CAAC,eAAe,EAAE,CAC7C,CACF,CAAA;IAED,QAAQ;QACN,IAAI,CAAC,aAAa,EAAE,CAAA;IACtB,CAAC;wGA1BU,wBAAwB;4FAAxB,wBAAwB,kNAJzB;;GAET;;4FAEU,wBAAwB;kBAPpC,SAAS;mBAAC;oBACT,QAAQ,EAAE,sBAAsB;oBAChC,UAAU,EAAE,KAAK;oBACjB,QAAQ,EAAE;;GAET;iBACF","sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed, input, type OnInit} from \"@angular/core\"\nimport {ChevronDown} from \"lucide-angular\"\n\nimport {useInlineIconButtonApi} from \"@qualcomm-ui/angular/inline-icon-button\"\nimport type {LucideIconOrString} from \"@qualcomm-ui/angular-core/lucide\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\nimport {useSelectContext} from \"@qualcomm-ui/angular-core/select\"\nimport {mergeProps} from \"@qualcomm-ui/utils/merge-props\"\n\nimport {useQdsSelectContext} from \"./qds-select-context.service\"\n\n@Component({\n selector: \"[q-select-indicator]\",\n standalone: false,\n template: `\n <svg [q-bind]=\"inlineIconButtonApi().getIconBindings()\" [qIcon]=\"icon()\" />\n `,\n})\nexport class SelectIndicatorDirective implements OnInit {\n /**\n * Indicator icon.\n *\n * @default ChevronDown\n */\n readonly icon = input<LucideIconOrString>(ChevronDown)\n\n protected readonly qdsSelectContext = useQdsSelectContext()\n protected readonly selectContext = useSelectContext()\n protected readonly inlineIconButtonApi = useInlineIconButtonApi({\n emphasis: \"neutral\",\n size: computed(() => (this.qdsSelectContext().size === \"sm\" ? \"sm\" : \"md\")),\n variant: \"scale\",\n })\n\n protected readonly trackBindings = useTrackBindings(() =>\n mergeProps(\n this.selectContext().getIndicatorBindings(),\n this.qdsSelectContext().getIndicatorBindings(),\n this.inlineIconButtonApi().getRootBindings(),\n ),\n )\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n"]}
|
|
@@ -103,7 +103,7 @@ export class SelectComponent extends SelectRootDirective {
|
|
|
103
103
|
}
|
|
104
104
|
</ng-content>
|
|
105
105
|
<ng-content select="[q-select-indicator]">
|
|
106
|
-
<
|
|
106
|
+
<button q-select-indicator></button>
|
|
107
107
|
</ng-content>
|
|
108
108
|
<ng-content select="[q-select-error-indicator]">
|
|
109
109
|
<div q-select-error-indicator></div>
|
|
@@ -177,7 +177,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.10", ngImpo
|
|
|
177
177
|
}
|
|
178
178
|
</ng-content>
|
|
179
179
|
<ng-content select="[q-select-indicator]">
|
|
180
|
-
<
|
|
180
|
+
<button q-select-indicator></button>
|
|
181
181
|
</ng-content>
|
|
182
182
|
<ng-content select="[q-select-error-indicator]">
|
|
183
183
|
<div q-select-error-indicator></div>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select.component.js","sourceRoot":"","sources":["../../../src/select/select.component.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EACL,gBAAgB,EAChB,uBAAuB,EACvB,SAAS,EACT,KAAK,GACN,MAAM,eAAe,CAAA;AAEtB,OAAO,EAAC,sBAAsB,EAAC,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAC,oBAAoB,EAAC,MAAM,kCAAkC,CAAA;AAGrE,OAAO,EAAC,uBAAuB,EAAC,MAAM,8BAA8B,CAAA;AACpE,OAAO,EAAC,mBAAmB,EAAC,MAAM,yBAAyB,CAAA;;;;;;;;;;;;;;;;;AA0E3D,MAAM,OAAO,eAAgB,SAAQ,mBAAmB;IACtD;;;OAGG;IACM,SAAS,GAAG,KAAK,CAAqB,SAAS,6CACtD,KAAK,EAAE,YAAY,OADqC;YACxD,KAAK,EAAE,YAAY;SACpB,GAAC,CAAA;IAEF;;;;;OAKG;IACM,SAAS,GAAG,KAAK,CAAkC,IAAI,6CAC9D,SAAS,EAAE,gBAAgB,OADqC;YAChE,SAAS,EAAE,gBAAgB;SAC5B,GAAC,CAAA;IAEF;;OAEG;IACM,aAAa,GAAG,KAAK,CAAkC,SAAS,iDACvE,SAAS,EAAE,gBAAgB,OAD8C;YACzE,SAAS,EAAE,gBAAgB;SAC5B,GAAC,CAAA;IAEF;;;;;;;;;OASG;IACM,SAAS,GAAG,KAAK,+DAA6B,CAAA;IAEvD;;;;;;;;;;OAUG;IACM,IAAI,GAAG,KAAK,0DAA6B,CAAA;IAElD;;;;;;;;;;;OAWG;IACM,KAAK,GAAG,KAAK,2DAAsB,CAAA;wGA/DjC,eAAe;4FAAf,eAAe,80BAtEf;YACT,oBAAoB,EAAE;YACtB,uBAAuB,EAAE;YACzB,sBAAsB,EAAE;SACzB,iDAGS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6DT;;4FAEU,eAAe;kBAxE3B,SAAS;mBAAC;oBACT,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,SAAS,EAAE;wBACT,oBAAoB,EAAE;wBACtB,uBAAuB,EAAE;wBACzB,sBAAsB,EAAE;qBACzB;oBACD,QAAQ,EAAE,UAAU;oBACpB,UAAU,EAAE,KAAK;oBACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6DT;iBACF","sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n input,\n} from \"@angular/core\"\n\nimport {provideQdsInputContext} from \"@qualcomm-ui/angular/input\"\nimport {provideSelectContext} from \"@qualcomm-ui/angular-core/select\"\nimport type {Booleanish} from \"@qualcomm-ui/utils/coercion\"\n\nimport {provideQdsSelectContext} from \"./qds-select-context.service\"\nimport {SelectRootDirective} from \"./select-root.directive\"\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n provideSelectContext(),\n provideQdsSelectContext(),\n provideQdsInputContext(),\n ],\n selector: \"q-select\",\n standalone: false,\n template: `\n <ng-content select=\"[q-select-label]\">\n @if (label()) {\n <div q-select-label>{{ label() }}</div>\n }\n </ng-content>\n\n <ng-content select=\"[q-select-control]\">\n <div q-select-control [attr.aria-label]=\"ariaLabel()\">\n <ng-content select=\"[q-select-value-text]\">\n <span q-select-value-text></span>\n </ng-content>\n <ng-content select=\"[q-select-clear-trigger]\">\n @if (clearable()) {\n <button q-select-clear-trigger></button>\n }\n </ng-content>\n <ng-content select=\"[q-select-indicator]\">\n <
|
|
1
|
+
{"version":3,"file":"select.component.js","sourceRoot":"","sources":["../../../src/select/select.component.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,8CAA8C;AAE9C,OAAO,EACL,gBAAgB,EAChB,uBAAuB,EACvB,SAAS,EACT,KAAK,GACN,MAAM,eAAe,CAAA;AAEtB,OAAO,EAAC,sBAAsB,EAAC,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAC,oBAAoB,EAAC,MAAM,kCAAkC,CAAA;AAGrE,OAAO,EAAC,uBAAuB,EAAC,MAAM,8BAA8B,CAAA;AACpE,OAAO,EAAC,mBAAmB,EAAC,MAAM,yBAAyB,CAAA;;;;;;;;;;;;;;;;;AA0E3D,MAAM,OAAO,eAAgB,SAAQ,mBAAmB;IACtD;;;OAGG;IACM,SAAS,GAAG,KAAK,CAAqB,SAAS,6CACtD,KAAK,EAAE,YAAY,OADqC;YACxD,KAAK,EAAE,YAAY;SACpB,GAAC,CAAA;IAEF;;;;;OAKG;IACM,SAAS,GAAG,KAAK,CAAkC,IAAI,6CAC9D,SAAS,EAAE,gBAAgB,OADqC;YAChE,SAAS,EAAE,gBAAgB;SAC5B,GAAC,CAAA;IAEF;;OAEG;IACM,aAAa,GAAG,KAAK,CAAkC,SAAS,iDACvE,SAAS,EAAE,gBAAgB,OAD8C;YACzE,SAAS,EAAE,gBAAgB;SAC5B,GAAC,CAAA;IAEF;;;;;;;;;OASG;IACM,SAAS,GAAG,KAAK,+DAA6B,CAAA;IAEvD;;;;;;;;;;OAUG;IACM,IAAI,GAAG,KAAK,0DAA6B,CAAA;IAElD;;;;;;;;;;;OAWG;IACM,KAAK,GAAG,KAAK,2DAAsB,CAAA;wGA/DjC,eAAe;4FAAf,eAAe,80BAtEf;YACT,oBAAoB,EAAE;YACtB,uBAAuB,EAAE;YACzB,sBAAsB,EAAE;SACzB,iDAGS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6DT;;4FAEU,eAAe;kBAxE3B,SAAS;mBAAC;oBACT,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,SAAS,EAAE;wBACT,oBAAoB,EAAE;wBACtB,uBAAuB,EAAE;wBACzB,sBAAsB,EAAE;qBACzB;oBACD,QAAQ,EAAE,UAAU;oBACpB,UAAU,EAAE,KAAK;oBACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6DT;iBACF","sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n input,\n} from \"@angular/core\"\n\nimport {provideQdsInputContext} from \"@qualcomm-ui/angular/input\"\nimport {provideSelectContext} from \"@qualcomm-ui/angular-core/select\"\nimport type {Booleanish} from \"@qualcomm-ui/utils/coercion\"\n\nimport {provideQdsSelectContext} from \"./qds-select-context.service\"\nimport {SelectRootDirective} from \"./select-root.directive\"\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n provideSelectContext(),\n provideQdsSelectContext(),\n provideQdsInputContext(),\n ],\n selector: \"q-select\",\n standalone: false,\n template: `\n <ng-content select=\"[q-select-label]\">\n @if (label()) {\n <div q-select-label>{{ label() }}</div>\n }\n </ng-content>\n\n <ng-content select=\"[q-select-control]\">\n <div q-select-control [attr.aria-label]=\"ariaLabel()\">\n <ng-content select=\"[q-select-value-text]\">\n <span q-select-value-text></span>\n </ng-content>\n <ng-content select=\"[q-select-clear-trigger]\">\n @if (clearable()) {\n <button q-select-clear-trigger></button>\n }\n </ng-content>\n <ng-content select=\"[q-select-indicator]\">\n <button q-select-indicator></button>\n </ng-content>\n <ng-content select=\"[q-select-error-indicator]\">\n <div q-select-error-indicator></div>\n </ng-content>\n </div>\n </ng-content>\n\n <ng-content select=\"[q-select-hint]\">\n @if (hint()) {\n <div q-select-hint>{{ hint() }}</div>\n }\n </ng-content>\n\n <ng-content select=\"[q-select-error-text]\">\n @if (errorText()) {\n <div q-select-error-text>{{ errorText() }}</div>\n }\n </ng-content>\n\n <ng-content select=\"q-select-hidden-select\">\n <select q-select-hidden-select></select>\n </ng-content>\n\n <ng-template qPortal [disabled]=\"disablePortal()\">\n <div q-select-positioner>\n <ng-content select=\"[q-select-content]\">\n <div q-select-content>\n @for (\n item of collection().items;\n track collection().getItemValue(item)\n ) {\n <div q-select-item [item]=\"item\">\n <span q-select-item-text>\n {{ collection().stringifyItem(item) }}\n </span>\n <span q-select-item-indicator></span>\n </div>\n }\n </div>\n </ng-content>\n </div>\n </ng-template>\n `,\n})\nexport class SelectComponent extends SelectRootDirective {\n /**\n * ARIA label applied to the control element. Use this if you omit the {@link\n * label}\n */\n readonly ariaLabel = input<string | undefined>(undefined, {\n alias: \"aria-label\",\n })\n\n /**\n * When `true`, renders a clear button that resets the input value on click.\n * The button only appears when the input has a value.\n *\n * @default true\n */\n readonly clearable = input<boolean | undefined, Booleanish>(true, {\n transform: booleanAttribute,\n })\n\n /**\n * Set to true to disable portalling behavior for the select dropdown content.\n */\n readonly disablePortal = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * Optional error that describes the element when {@link invalid} is true.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <div q-select-error-text>...</div>\n * ```\n */\n readonly errorText = input<string | undefined | null>()\n\n /**\n * Optional hint describing the element. This element is automatically\n * associated with the component's input element for accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <div q-select-hint>...</div>\n * ```\n */\n readonly hint = input<string | undefined | null>()\n\n /**\n * Optional label describing the element. Recommended. This element is\n * automatically associated with the component's input element for\n * accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <div q-select-label>...</div>\n * ```\n */\n readonly label = input<string | undefined>()\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qualcomm-ui/angular",
|
|
3
|
-
"description": "
|
|
4
|
-
"version": "1.0.
|
|
3
|
+
"description": "QUI Angular Components",
|
|
4
|
+
"version": "1.0.2",
|
|
5
5
|
"author": "Ryan Bower",
|
|
6
|
+
"license": "BSD-3-Clause-Clear",
|
|
7
|
+
"repository": "https://github.com/qualcomm/qualcomm-ui",
|
|
6
8
|
"sideEffects": false,
|
|
7
9
|
"type": "module",
|
|
8
10
|
"module": "esm2022/qualcomm-ui-angular.js",
|
|
@@ -176,7 +178,6 @@
|
|
|
176
178
|
"tslib": "^2.3.0"
|
|
177
179
|
},
|
|
178
180
|
"peerDependencies": {
|
|
179
|
-
"@angular/animations": ">=20.1.0 <21",
|
|
180
181
|
"@angular/cdk": ">=20.1.0 <21",
|
|
181
182
|
"@angular/common": ">=20.1.0 <21",
|
|
182
183
|
"@angular/compiler": ">=20.1.0 <21",
|
|
@@ -184,18 +185,18 @@
|
|
|
184
185
|
"@angular/forms": ">=20.1.0 <21",
|
|
185
186
|
"@angular/platform-browser": ">=20.1.0 <21",
|
|
186
187
|
"@angular/platform-browser-dynamic": ">=20.1.0 <21",
|
|
187
|
-
"@qualcomm-ui/angular-core": "^1",
|
|
188
|
-
"@qualcomm-ui/core": "^1",
|
|
189
|
-
"@qualcomm-ui/qds-core": "^1",
|
|
188
|
+
"@qualcomm-ui/angular-core": "^1.0.2",
|
|
189
|
+
"@qualcomm-ui/core": "^1.0.3",
|
|
190
|
+
"@qualcomm-ui/qds-core": "^1.0.5",
|
|
190
191
|
"@qualcomm-ui/utils": "^1",
|
|
191
192
|
"@tanstack/virtual-core": ">=3.13.12",
|
|
192
193
|
"lucide-angular": ">=0.487.0 <1",
|
|
193
194
|
"typescript": ">=5.2.0 <6"
|
|
194
195
|
},
|
|
195
196
|
"private": false,
|
|
196
|
-
"types": "./index.d.ts",
|
|
197
|
-
"main": "./esm2022/qui-angular.mjs",
|
|
198
197
|
"publishConfig": {
|
|
199
198
|
"access": "public"
|
|
200
|
-
}
|
|
199
|
+
},
|
|
200
|
+
"types": "./index.d.ts",
|
|
201
|
+
"main": "./esm2022/qui-angular.mjs"
|
|
201
202
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { type OnInit } from "@angular/core";
|
|
1
2
|
import type { LucideIconOrString } from "@qualcomm-ui/angular-core/lucide";
|
|
2
3
|
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class SelectIndicatorDirective {
|
|
4
|
+
export declare class SelectIndicatorDirective implements OnInit {
|
|
4
5
|
/**
|
|
5
6
|
* Indicator icon.
|
|
6
7
|
*
|
|
@@ -9,7 +10,12 @@ export declare class SelectIndicatorDirective {
|
|
|
9
10
|
readonly icon: import("@angular/core").InputSignal<LucideIconOrString>;
|
|
10
11
|
protected readonly qdsSelectContext: () => import("@qualcomm-ui/qds-core/select").QdsSelectApi;
|
|
11
12
|
protected readonly selectContext: () => import("@qualcomm-ui/core/select").SelectApi<any>;
|
|
12
|
-
readonly
|
|
13
|
+
protected readonly inlineIconButtonApi: import("@angular/core").Signal<import("@qualcomm-ui/qds-core/inline-icon-button").QdsInlineIconButtonApi>;
|
|
14
|
+
protected readonly trackBindings: ((opts?: import("@qualcomm-ui/angular-core/machine").TrackBindingsConfig) => void) & {
|
|
15
|
+
extendWith: (computedProps: () => import("@qualcomm-ui/angular-core/machine").Dict) => void;
|
|
16
|
+
setDisabled: (disabled: boolean) => void;
|
|
17
|
+
};
|
|
18
|
+
ngOnInit(): void;
|
|
13
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectIndicatorDirective, never>;
|
|
14
20
|
static ɵcmp: i0.ɵɵComponentDeclaration<SelectIndicatorDirective, "[q-select-indicator]", never, { "icon": { "alias": "icon"; "required": false; "isSignal": true; }; }, {}, never, never, false, never>;
|
|
15
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-indicator.directive.d.ts","sourceRoot":"","sources":["../../../src/select/select-indicator.directive.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"select-indicator.directive.d.ts","sourceRoot":"","sources":["../../../src/select/select-indicator.directive.ts"],"names":[],"mappings":"AAGA,OAAO,EAA6B,KAAK,MAAM,EAAC,MAAM,eAAe,CAAA;AAIrE,OAAO,KAAK,EAAC,kBAAkB,EAAC,MAAM,kCAAkC,CAAA;;AAOxE,qBAOa,wBAAyB,YAAW,MAAM;IACrD;;;;OAIG;IACH,QAAQ,CAAC,IAAI,0DAAyC;IAEtD,SAAS,CAAC,QAAQ,CAAC,gBAAgB,4DAAwB;IAC3D,SAAS,CAAC,QAAQ,CAAC,aAAa,0DAAqB;IACrD,SAAS,CAAC,QAAQ,CAAC,mBAAmB,4GAIpC;IAEF,SAAS,CAAC,QAAQ,CAAC,aAAa;;;MAM/B;IAED,QAAQ;yCAxBG,wBAAwB;2CAAxB,wBAAwB;CA2BpC"}
|