ember-container-query 4.0.3 → 4.0.5
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/{dist → declarations}/components/container-query.d.ts +5 -4
- package/declarations/components/container-query.d.ts.map +1 -0
- package/{dist → declarations}/helpers/aspect-ratio.d.ts +3 -3
- package/declarations/helpers/aspect-ratio.d.ts.map +1 -0
- package/{dist → declarations}/helpers/height.d.ts +3 -3
- package/declarations/helpers/height.d.ts.map +1 -0
- package/{dist → declarations}/helpers/width.d.ts +3 -3
- package/declarations/helpers/width.d.ts.map +1 -0
- package/declarations/index.d.ts +7 -0
- package/declarations/index.d.ts.map +1 -0
- package/{dist → declarations}/modifiers/container-query.d.ts +5 -6
- package/declarations/modifiers/container-query.d.ts.map +1 -0
- package/declarations/template-registry.d.ts +13 -0
- package/declarations/template-registry.d.ts.map +1 -0
- package/dist/{applyDecoratedDescriptor-fa858ac4.js → _rollupPluginBabelHelpers-e795903d.js} +24 -38
- package/dist/_rollupPluginBabelHelpers-e795903d.js.map +1 -0
- package/dist/components/container-query.js +2 -2
- package/dist/components/container-query.js.map +1 -1
- package/dist/helpers/aspect-ratio.js.map +1 -1
- package/dist/helpers/height.js.map +1 -1
- package/dist/helpers/width.js.map +1 -1
- package/dist/modifiers/container-query.js +1 -1
- package/package.json +41 -33
- package/dist/applyDecoratedDescriptor-fa858ac4.js.map +0 -1
- package/dist/components/container-query.d.ts.map +0 -1
- package/dist/index.d.ts +0 -6
- package/dist/template-registry.d.ts +0 -13
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import './container-query.css';
|
|
1
2
|
import Component from '@glimmer/component';
|
|
2
|
-
import { Dimensions, Features, IndexSignatureParameter, QueryResults } from
|
|
3
|
+
import type { Dimensions, Features, IndexSignatureParameter, QueryResults } from '../modifiers/container-query.ts';
|
|
3
4
|
interface ContainerQuerySignature<T extends IndexSignatureParameter> {
|
|
4
5
|
Args: {
|
|
5
6
|
dataAttributePrefix?: string;
|
|
@@ -17,7 +18,7 @@ interface ContainerQuerySignature<T extends IndexSignatureParameter> {
|
|
|
17
18
|
};
|
|
18
19
|
Element: HTMLElement;
|
|
19
20
|
}
|
|
20
|
-
|
|
21
|
+
export default class ContainerQueryComponent<T extends IndexSignatureParameter> extends Component<ContainerQuerySignature<T>> {
|
|
21
22
|
dimensions?: Dimensions;
|
|
22
23
|
queryResults?: QueryResults<T>;
|
|
23
24
|
tagName: string;
|
|
@@ -26,5 +27,5 @@ declare class ContainerQueryComponent<T extends IndexSignatureParameter> extends
|
|
|
26
27
|
queryResults: QueryResults<T>;
|
|
27
28
|
}): void;
|
|
28
29
|
}
|
|
29
|
-
export {
|
|
30
|
-
//# sourceMappingURL=
|
|
30
|
+
export {};
|
|
31
|
+
//# sourceMappingURL=container-query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"container-query.d.ts","sourceRoot":"","sources":["../../src/components/container-query.ts"],"names":[],"mappings":"AAAA,OAAO,uBAAuB,CAAC;AAG/B,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAG3C,OAAO,KAAK,EACV,UAAU,EACV,QAAQ,EACR,uBAAuB,EACvB,YAAY,EACb,MAAM,iCAAiC,CAAC;AAEzC,UAAU,uBAAuB,CAAC,CAAC,SAAS,uBAAuB;IACjE,IAAI,EAAE;QACJ,mBAAmB,CAAC,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;QACvB,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,CAAC;IACF,MAAM,EAAE;QACN,OAAO,EAAE;YACP;gBACE,UAAU,CAAC,EAAE,UAAU,CAAC;gBACxB,QAAQ,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;aAC5B;SACF,CAAC;KACH,CAAC;IACF,OAAO,EAAE,WAAW,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,OAAO,uBAAuB,CAC1C,CAAC,SAAS,uBAAuB,CACjC,SAAQ,SAAS,CAAC,uBAAuB,CAAC,CAAC,CAAC,CAAC;IACpC,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,YAAY,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;IAGxC,OAAO,SAA8B;IAE7B,WAAW,CAAC,EAClB,UAAU,EACV,YAAY,GACb,EAAE;QACD,UAAU,EAAE,UAAU,CAAC;QACvB,YAAY,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;KAC/B,GAAG,IAAI;CA+BT"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { Metadata } from "../modifiers/container-query.js";
|
|
1
|
+
import type { Metadata } from '../modifiers/container-query.ts';
|
|
3
2
|
declare const AspectRatioHelper: import("@ember/component/helper").FunctionBasedHelper<{
|
|
4
3
|
Args: {
|
|
5
4
|
Positional: [];
|
|
@@ -10,4 +9,5 @@ declare const AspectRatioHelper: import("@ember/component/helper").FunctionBased
|
|
|
10
9
|
};
|
|
11
10
|
Return: Metadata;
|
|
12
11
|
}>;
|
|
13
|
-
export
|
|
12
|
+
export default AspectRatioHelper;
|
|
13
|
+
//# sourceMappingURL=aspect-ratio.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aspect-ratio.d.ts","sourceRoot":"","sources":["../../src/helpers/aspect-ratio.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAahE,QAAA,MAAM,iBAAiB;;;;;;;;;EAQtB,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { Metadata } from "../modifiers/container-query.js";
|
|
1
|
+
import type { Metadata } from '../modifiers/container-query.ts';
|
|
3
2
|
declare const HeightHelper: import("@ember/component/helper").FunctionBasedHelper<{
|
|
4
3
|
Args: {
|
|
5
4
|
Positional: [];
|
|
@@ -10,4 +9,5 @@ declare const HeightHelper: import("@ember/component/helper").FunctionBasedHelpe
|
|
|
10
9
|
};
|
|
11
10
|
Return: Metadata;
|
|
12
11
|
}>;
|
|
13
|
-
export
|
|
12
|
+
export default HeightHelper;
|
|
13
|
+
//# sourceMappingURL=height.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"height.d.ts","sourceRoot":"","sources":["../../src/helpers/height.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAahE,QAAA,MAAM,YAAY;;;;;;;;;EAMhB,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { Metadata } from "../modifiers/container-query.js";
|
|
1
|
+
import type { Metadata } from '../modifiers/container-query.ts';
|
|
3
2
|
declare const WidthHelper: import("@ember/component/helper").FunctionBasedHelper<{
|
|
4
3
|
Args: {
|
|
5
4
|
Positional: [];
|
|
@@ -10,4 +9,5 @@ declare const WidthHelper: import("@ember/component/helper").FunctionBasedHelper
|
|
|
10
9
|
};
|
|
11
10
|
Return: Metadata;
|
|
12
11
|
}>;
|
|
13
|
-
export
|
|
12
|
+
export default WidthHelper;
|
|
13
|
+
//# sourceMappingURL=width.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"width.d.ts","sourceRoot":"","sources":["../../src/helpers/width.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAahE,QAAA,MAAM,WAAW;;;;;;;;;EAMf,CAAC;AAEH,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { default as ContainerQuery } from './components/container-query.ts';
|
|
2
|
+
export { default as aspectRatio } from './helpers/aspect-ratio.ts';
|
|
3
|
+
export { default as height } from './helpers/height.ts';
|
|
4
|
+
export { default as width } from './helpers/width.ts';
|
|
5
|
+
export type { Dimensions, Features, IndexSignatureParameter, Metadata, QueryResults, } from './modifiers/container-query.ts';
|
|
6
|
+
export { default as containerQuery } from './modifiers/container-query.ts';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAC5E,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACnE,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EACV,UAAU,EACV,QAAQ,EACR,uBAAuB,EACvB,QAAQ,EACR,YAAY,GACb,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,gCAAgC,CAAC"}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import Modifier from 'ember-modifier';
|
|
4
|
-
import { ArgsFor, NamedArgs, PositionalArgs } from "ember-modifier";
|
|
1
|
+
import type Owner from '@ember/owner';
|
|
2
|
+
import Modifier, { ArgsFor, NamedArgs, PositionalArgs } from 'ember-modifier';
|
|
5
3
|
type IndexSignatureParameter = string | number | symbol;
|
|
6
4
|
type Dimensions = {
|
|
7
5
|
aspectRatio: number;
|
|
@@ -30,7 +28,7 @@ interface ContainerQueryModifierSignature<T extends IndexSignatureParameter> {
|
|
|
30
28
|
};
|
|
31
29
|
Element: Element;
|
|
32
30
|
}
|
|
33
|
-
|
|
31
|
+
export default class ContainerQueryModifier<T extends IndexSignatureParameter> extends Modifier<ContainerQueryModifierSignature<T>> {
|
|
34
32
|
private readonly resizeObserver;
|
|
35
33
|
dimensions: Dimensions;
|
|
36
34
|
queryResults: QueryResults<T>;
|
|
@@ -50,4 +48,5 @@ declare class ContainerQueryModifier<T extends IndexSignatureParameter> extends
|
|
|
50
48
|
private resetDataAttributes;
|
|
51
49
|
private setDataAttributes;
|
|
52
50
|
}
|
|
53
|
-
export {
|
|
51
|
+
export { Dimensions, Features, IndexSignatureParameter, Metadata, QueryResults, };
|
|
52
|
+
//# sourceMappingURL=container-query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"container-query.d.ts","sourceRoot":"","sources":["../../src/modifiers/container-query.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AAGtC,OAAO,QAAQ,EAAE,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAE9E,KAAK,uBAAuB,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;AAIxD,KAAK,UAAU,GAAG;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,KAAK,QAAQ,GAAG;IACd,SAAS,EAAE,MAAM,UAAU,CAAC;IAC5B,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;CACb,CAAC;AAEF,KAAK,QAAQ,CAAC,CAAC,SAAS,uBAAuB,IAAI,MAAM,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC;AAEvE,KAAK,YAAY,CAAC,CAAC,SAAS,uBAAuB,IAAI,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;AAE1E,UAAU,+BAA+B,CAAC,CAAC,SAAS,uBAAuB;IACzE,IAAI,EAAE;QACJ,KAAK,EAAE;YACL,mBAAmB,CAAC,EAAE,MAAM,CAAC;YAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;YAClB,QAAQ,CAAC,EAAE,QA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V,QAAQ,EACR,uBAAuB,EACvB,QAAQ,EACR,YAAY,GACb,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type ContainerQueryComponent from './components/container-query.ts';
|
|
2
|
+
import type AspectRatioHelper from './helpers/aspect-ratio.ts';
|
|
3
|
+
import type HeightHelper from './helpers/height.ts';
|
|
4
|
+
import type WidthHelper from './helpers/width.ts';
|
|
5
|
+
import type ContainerQueryModifier from './modifiers/container-query.ts';
|
|
6
|
+
export default interface EmberContainerQueryRegistry {
|
|
7
|
+
ContainerQuery: typeof ContainerQueryComponent;
|
|
8
|
+
'aspect-ratio': typeof AspectRatioHelper;
|
|
9
|
+
'container-query': typeof ContainerQueryModifier;
|
|
10
|
+
height: typeof HeightHelper;
|
|
11
|
+
width: typeof WidthHelper;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=template-registry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"template-registry.d.ts","sourceRoot":"","sources":["../src/template-registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,uBAAuB,MAAM,iCAAiC,CAAC;AAC3E,OAAO,KAAK,iBAAiB,MAAM,2BAA2B,CAAC;AAC/D,OAAO,KAAK,YAAY,MAAM,qBAAqB,CAAC;AACpD,OAAO,KAAK,WAAW,MAAM,oBAAoB,CAAC;AAClD,OAAO,KAAK,sBAAsB,MAAM,gCAAgC,CAAC;AAEzE,MAAM,CAAC,OAAO,WAAW,2BAA2B;IAClD,cAAc,EAAE,OAAO,uBAAuB,CAAC;IAC/C,cAAc,EAAE,OAAO,iBAAiB,CAAC;IACzC,iBAAiB,EAAE,OAAO,sBAAsB,CAAC;IACjD,MAAM,EAAE,OAAO,YAAY,CAAC;IAC5B,KAAK,EAAE,OAAO,WAAW,CAAC;CAC3B"}
|
|
@@ -1,39 +1,3 @@
|
|
|
1
|
-
function _initializerDefineProperty(target, property, descriptor, context) {
|
|
2
|
-
if (!descriptor) return;
|
|
3
|
-
Object.defineProperty(target, property, {
|
|
4
|
-
enumerable: descriptor.enumerable,
|
|
5
|
-
configurable: descriptor.configurable,
|
|
6
|
-
writable: descriptor.writable,
|
|
7
|
-
value: descriptor.initializer ? descriptor.initializer.call(context) : void 0
|
|
8
|
-
});
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
function _typeof(obj) {
|
|
12
|
-
"@babel/helpers - typeof";
|
|
13
|
-
|
|
14
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
15
|
-
return typeof obj;
|
|
16
|
-
} : function (obj) {
|
|
17
|
-
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
18
|
-
}, _typeof(obj);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
function _toPrimitive(input, hint) {
|
|
22
|
-
if (_typeof(input) !== "object" || input === null) return input;
|
|
23
|
-
var prim = input[Symbol.toPrimitive];
|
|
24
|
-
if (prim !== undefined) {
|
|
25
|
-
var res = prim.call(input, hint || "default");
|
|
26
|
-
if (_typeof(res) !== "object") return res;
|
|
27
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
28
|
-
}
|
|
29
|
-
return (hint === "string" ? String : Number)(input);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
function _toPropertyKey(arg) {
|
|
33
|
-
var key = _toPrimitive(arg, "string");
|
|
34
|
-
return _typeof(key) === "symbol" ? key : String(key);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
1
|
function _defineProperty(obj, key, value) {
|
|
38
2
|
key = _toPropertyKey(key);
|
|
39
3
|
if (key in obj) {
|
|
@@ -48,7 +12,29 @@ function _defineProperty(obj, key, value) {
|
|
|
48
12
|
}
|
|
49
13
|
return obj;
|
|
50
14
|
}
|
|
51
|
-
|
|
15
|
+
function _toPrimitive(input, hint) {
|
|
16
|
+
if (typeof input !== "object" || input === null) return input;
|
|
17
|
+
var prim = input[Symbol.toPrimitive];
|
|
18
|
+
if (prim !== undefined) {
|
|
19
|
+
var res = prim.call(input, hint || "default");
|
|
20
|
+
if (typeof res !== "object") return res;
|
|
21
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
22
|
+
}
|
|
23
|
+
return (hint === "string" ? String : Number)(input);
|
|
24
|
+
}
|
|
25
|
+
function _toPropertyKey(arg) {
|
|
26
|
+
var key = _toPrimitive(arg, "string");
|
|
27
|
+
return typeof key === "symbol" ? key : String(key);
|
|
28
|
+
}
|
|
29
|
+
function _initializerDefineProperty(target, property, descriptor, context) {
|
|
30
|
+
if (!descriptor) return;
|
|
31
|
+
Object.defineProperty(target, property, {
|
|
32
|
+
enumerable: descriptor.enumerable,
|
|
33
|
+
configurable: descriptor.configurable,
|
|
34
|
+
writable: descriptor.writable,
|
|
35
|
+
value: descriptor.initializer ? descriptor.initializer.call(context) : void 0
|
|
36
|
+
});
|
|
37
|
+
}
|
|
52
38
|
function _applyDecoratedDescriptor(target, property, decorators, descriptor, context) {
|
|
53
39
|
var desc = {};
|
|
54
40
|
Object.keys(descriptor).forEach(function (key) {
|
|
@@ -74,4 +60,4 @@ function _applyDecoratedDescriptor(target, property, decorators, descriptor, con
|
|
|
74
60
|
}
|
|
75
61
|
|
|
76
62
|
export { _applyDecoratedDescriptor as _, _initializerDefineProperty as a, _defineProperty as b };
|
|
77
|
-
//# sourceMappingURL=
|
|
63
|
+
//# sourceMappingURL=_rollupPluginBabelHelpers-e795903d.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_rollupPluginBabelHelpers-e795903d.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _applyDecoratedDescriptor, a as _initializerDefineProperty, b as _defineProperty } from '../
|
|
1
|
+
import { _ as _applyDecoratedDescriptor, a as _initializerDefineProperty, b as _defineProperty } from '../_rollupPluginBabelHelpers-e795903d.js';
|
|
2
2
|
import { setComponentTemplate } from '@ember/component';
|
|
3
3
|
import { precompileTemplate } from '@ember/template-compilation';
|
|
4
4
|
import './container-query.css';
|
|
@@ -6,7 +6,7 @@ import { action } from '@ember/object';
|
|
|
6
6
|
import Component from '@glimmer/component';
|
|
7
7
|
import { tracked } from '@glimmer/tracking';
|
|
8
8
|
|
|
9
|
-
var TEMPLATE = precompileTemplate("{{
|
|
9
|
+
var TEMPLATE = precompileTemplate("{{#let (element this.tagName) as |Tag|}}\n <Tag\n class=\"container-query\"\n {{container-query\n dataAttributePrefix=@dataAttributePrefix\n debounce=@debounce\n features=@features\n onQuery=this.updateState\n }}\n ...attributes\n >\n {{yield\n (hash\n dimensions=this.dimensions\n features=this.queryResults\n )\n }}\n </Tag>\n{{/let}}");
|
|
10
10
|
|
|
11
11
|
var _class, _descriptor, _descriptor2;
|
|
12
12
|
let ContainerQueryComponent = (_class = class ContainerQueryComponent extends Component {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"container-query.js","sources":["../../src/components/container-query.hbs.js","../../src/components/container-query.ts"],"sourcesContent":["import { precompileTemplate } from \"@ember/template-compilation\";\nexport default precompileTemplate(\"{{
|
|
1
|
+
{"version":3,"file":"container-query.js","sources":["../../src/components/container-query.hbs.js","../../src/components/container-query.ts"],"sourcesContent":["import { precompileTemplate } from \"@ember/template-compilation\";\nexport default precompileTemplate(\"{{#let (element this.tagName) as |Tag|}}\\n <Tag\\n class=\\\"container-query\\\"\\n {{container-query\\n dataAttributePrefix=@dataAttributePrefix\\n debounce=@debounce\\n features=@features\\n onQuery=this.updateState\\n }}\\n ...attributes\\n >\\n {{yield\\n (hash\\n dimensions=this.dimensions\\n features=this.queryResults\\n )\\n }}\\n </Tag>\\n{{/let}}\")","import './container-query.css';\n\nimport { action } from '@ember/object';\nimport Component from '@glimmer/component';\nimport { tracked } from '@glimmer/tracking';\n\nimport type {\n Dimensions,\n Features,\n IndexSignatureParameter,\n QueryResults,\n} from '../modifiers/container-query.ts';\n\ninterface ContainerQuerySignature<T extends IndexSignatureParameter> {\n Args: {\n dataAttributePrefix?: string;\n debounce?: number;\n features?: Features<T>;\n tagName?: string;\n };\n Blocks: {\n default: [\n {\n dimensions?: Dimensions;\n features?: QueryResults<T>;\n },\n ];\n };\n Element: HTMLElement;\n}\n\nexport default class ContainerQueryComponent<\n T extends IndexSignatureParameter,\n> extends Component<ContainerQuerySignature<T>> {\n @tracked dimensions?: Dimensions;\n @tracked queryResults?: QueryResults<T>;\n\n // The dynamic tag is restricted to be immutable\n tagName = this.args.tagName ?? 'div';\n\n @action updateState({\n dimensions,\n queryResults,\n }: {\n dimensions: Dimensions;\n queryResults: QueryResults<T>;\n }): void {\n this.dimensions = dimensions;\n this.queryResults = queryResults;\n }\n}\n"],"names":["precompileTemplate","ContainerQueryComponent","_class","Component","constructor","args","_initializerDefineProperty","_descriptor","_descriptor2","_defineProperty","tagName","updateState","dimensions","queryResults","_applyDecoratedDescriptor","prototype","tracked","configurable","enumerable","writable","initializer","action","Object","getOwnPropertyDescriptor","setComponentTemplate","TEMPLATE"],"mappings":";;;;;;;;AACA,eAAeA,kBAAkB,CAAC,mZAAmZ,CAAC;;;AC8BjaC,IAAAA,uBAAuB,IAAAC,MAAA,GAA7B,MAAMD,uBAAuB,SAElCE,SAAS,CAA6B;AAAAC,EAAAA,WAAAA,CAAA,GAAAC,IAAA,EAAA;AAAA,IAAA,KAAA,CAAA,GAAAA,IAAA,CAAA,CAAA;AAAAC,IAAAA,0BAAA,qBAAAC,WAAA,EAAA,IAAA,CAAA,CAAA;AAAAD,IAAAA,0BAAA,uBAAAE,YAAA,EAAA,IAAA,CAAA,CAAA;AAI9C;AAAAC,IAAAA,eAAA,kBACU,IAAI,CAACJ,IAAI,CAACK,OAAO,IAAI,KAAK,CAAA,CAAA;AAAA,GAAA;AAE5BC,EAAAA,WAAWA,CAAC;IAClBC,UAAU;AACVC,IAAAA,YAAAA;AAIF,GAAC,EAAQ;IACP,IAAI,CAACD,UAAU,GAAGA,UAAU,CAAA;IAC5B,IAAI,CAACC,YAAY,GAAGA,YAAY,CAAA;AAClC,GAAA;AACF,CAAC,GAAAN,WAAA,GAAAO,yBAAA,CAAAZ,MAAA,CAAAa,SAAA,EAAA,YAAA,EAAA,CAhBEC,OAAO,CAAA,EAAA;EAAAC,YAAA,EAAA,IAAA;EAAAC,UAAA,EAAA,IAAA;EAAAC,QAAA,EAAA,IAAA;EAAAC,WAAA,EAAA,IAAA;AAAA,CAAAZ,CAAAA,EAAAA,YAAA,GAAAM,yBAAA,CAAAZ,MAAA,CAAAa,SAAA,mBACPC,OAAO,CAAA,EAAA;EAAAC,YAAA,EAAA,IAAA;EAAAC,UAAA,EAAA,IAAA;EAAAC,QAAA,EAAA,IAAA;EAAAC,WAAA,EAAA,IAAA;AAAA,CAAAN,CAAAA,EAAAA,yBAAA,CAAAZ,MAAA,CAAAa,SAAA,EAKPM,aAAAA,EAAAA,CAAAA,MAAM,GAAAC,MAAA,CAAAC,wBAAA,CAAArB,MAAA,CAAAa,SAAA,EAAA,aAAA,CAAA,EAAAb,MAAA,CAAAa,SAAA,IAAAb,MAAA,EAAA;AATmCsB,oBAAA,CAAAC,QAAA,EAAAxB,uBAAA,CAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aspect-ratio.js","sources":["../../src/helpers/aspect-ratio.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query';\n\ninterface AspectRatioHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst AspectRatioHelper = helper<AspectRatioHelperSignature>(\n (_positional, named) => {\n const dimension = 'aspectRatio';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n },\n);\n\nexport default AspectRatioHelper;\n"],"names":["AspectRatioHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,iBAAiB,GAAGC,MAAM,CAC9B,CAACC,WAAW,EAAEC,KAAK,KAAK;EACtB,MAAMC,SAAS,GAAG,aAAa,CAAA;AAC/B,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CACF;;;;"}
|
|
1
|
+
{"version":3,"file":"aspect-ratio.js","sources":["../../src/helpers/aspect-ratio.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query.ts';\n\ninterface AspectRatioHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst AspectRatioHelper = helper<AspectRatioHelperSignature>(\n (_positional, named) => {\n const dimension = 'aspectRatio';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n },\n);\n\nexport default AspectRatioHelper;\n"],"names":["AspectRatioHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,iBAAiB,GAAGC,MAAM,CAC9B,CAACC,WAAW,EAAEC,KAAK,KAAK;EACtB,MAAMC,SAAS,GAAG,aAAa,CAAA;AAC/B,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CACF;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"height.js","sources":["../../src/helpers/height.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query';\n\ninterface HeightHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst HeightHelper = helper<HeightHelperSignature>((_positional, named) => {\n const dimension = 'height';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n});\n\nexport default HeightHelper;\n"],"names":["HeightHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,YAAY,GAAGC,MAAM,CAAwB,CAACC,WAAW,EAAEC,KAAK,KAAK;EACzE,MAAMC,SAAS,GAAG,QAAQ,CAAA;AAC1B,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"height.js","sources":["../../src/helpers/height.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query.ts';\n\ninterface HeightHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst HeightHelper = helper<HeightHelperSignature>((_positional, named) => {\n const dimension = 'height';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n});\n\nexport default HeightHelper;\n"],"names":["HeightHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,YAAY,GAAGC,MAAM,CAAwB,CAACC,WAAW,EAAEC,KAAK,KAAK;EACzE,MAAMC,SAAS,GAAG,QAAQ,CAAA;AAC1B,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CAAC;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"width.js","sources":["../../src/helpers/width.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query';\n\ninterface WidthHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst WidthHelper = helper<WidthHelperSignature>((_positional, named) => {\n const dimension = 'width';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n});\n\nexport default WidthHelper;\n"],"names":["WidthHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,WAAW,GAAGC,MAAM,CAAuB,CAACC,WAAW,EAAEC,KAAK,KAAK;EACvE,MAAMC,SAAS,GAAG,OAAO,CAAA;AACzB,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"width.js","sources":["../../src/helpers/width.ts"],"sourcesContent":["import { helper } from '@ember/component/helper';\n\nimport type { Metadata } from '../modifiers/container-query.ts';\n\ninterface WidthHelperSignature {\n Args: {\n Named: {\n max?: number;\n min?: number;\n };\n Positional: [];\n };\n Return: Metadata;\n}\n\nconst WidthHelper = helper<WidthHelperSignature>((_positional, named) => {\n const dimension = 'width';\n const max = named.max ?? Infinity;\n const min = named.min ?? 0;\n\n return { dimension, max, min };\n});\n\nexport default WidthHelper;\n"],"names":["WidthHelper","helper","_positional","named","dimension","max","Infinity","min"],"mappings":";;AAeMA,MAAAA,WAAW,GAAGC,MAAM,CAAuB,CAACC,WAAW,EAAEC,KAAK,KAAK;EACvE,MAAMC,SAAS,GAAG,OAAO,CAAA;AACzB,EAAA,MAAMC,GAAG,GAAGF,KAAK,CAACE,GAAG,IAAIC,QAAQ,CAAA;AACjC,EAAA,MAAMC,GAAG,GAAGJ,KAAK,CAACI,GAAG,IAAI,CAAC,CAAA;EAE1B,OAAO;IAAEH,SAAS;IAAEC,GAAG;AAAEE,IAAAA,GAAAA;GAAK,CAAA;AAChC,CAAC;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _applyDecoratedDescriptor, a as _initializerDefineProperty, b as _defineProperty } from '../
|
|
1
|
+
import { _ as _applyDecoratedDescriptor, a as _initializerDefineProperty, b as _defineProperty } from '../_rollupPluginBabelHelpers-e795903d.js';
|
|
2
2
|
import { registerDestructor } from '@ember/destroyable';
|
|
3
3
|
import { action } from '@ember/object';
|
|
4
4
|
import { debounce } from '@ember/runloop';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ember-container-query",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.5",
|
|
4
4
|
"description": "Make container queries that harness the power of Ember",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"container-queries",
|
|
@@ -21,9 +21,12 @@
|
|
|
21
21
|
"license": "MIT",
|
|
22
22
|
"author": "Isaac J. Lee",
|
|
23
23
|
"exports": {
|
|
24
|
-
".":
|
|
24
|
+
".": {
|
|
25
|
+
"types": "./declarations/index.d.ts",
|
|
26
|
+
"default": "./dist/index.js"
|
|
27
|
+
},
|
|
25
28
|
"./*": {
|
|
26
|
-
"types": "./
|
|
29
|
+
"types": "./declarations/*.d.ts",
|
|
27
30
|
"default": "./dist/*.js"
|
|
28
31
|
},
|
|
29
32
|
"./addon-main.js": "./addon-main.cjs"
|
|
@@ -31,7 +34,7 @@
|
|
|
31
34
|
"typesVersions": {
|
|
32
35
|
"*": {
|
|
33
36
|
"*": [
|
|
34
|
-
"
|
|
37
|
+
"declarations/*"
|
|
35
38
|
]
|
|
36
39
|
}
|
|
37
40
|
},
|
|
@@ -41,51 +44,52 @@
|
|
|
41
44
|
},
|
|
42
45
|
"files": [
|
|
43
46
|
"addon-main.cjs",
|
|
47
|
+
"declarations",
|
|
44
48
|
"dist"
|
|
45
49
|
],
|
|
46
50
|
"dependencies": {
|
|
47
51
|
"@embroider/addon-shim": "^1.8.5",
|
|
48
|
-
"ember-element-helper": "^0.
|
|
52
|
+
"ember-element-helper": "^0.7.1",
|
|
49
53
|
"ember-modifier": "^3.2.7 || ^4.1.0",
|
|
50
54
|
"ember-resize-observer-service": "^1.1.0"
|
|
51
55
|
},
|
|
52
56
|
"devDependencies": {
|
|
53
|
-
"@babel/core": "^7.22.
|
|
57
|
+
"@babel/core": "^7.22.9",
|
|
54
58
|
"@babel/plugin-proposal-class-properties": "^7.18.6",
|
|
55
|
-
"@babel/plugin-proposal-decorators": "^7.22.
|
|
56
|
-
"@babel/preset-typescript": "^7.
|
|
57
|
-
"@babel/runtime": "^7.22.
|
|
59
|
+
"@babel/plugin-proposal-decorators": "^7.22.7",
|
|
60
|
+
"@babel/preset-typescript": "^7.22.5",
|
|
61
|
+
"@babel/runtime": "^7.22.6",
|
|
58
62
|
"@embroider/addon-dev": "^3.1.1",
|
|
59
|
-
"@gavant/glint-template-types": "^0.3.
|
|
63
|
+
"@gavant/glint-template-types": "^0.3.4",
|
|
60
64
|
"@glimmer/component": "^1.1.2",
|
|
61
65
|
"@glimmer/tracking": "^1.1.2",
|
|
62
66
|
"@glint/core": "^1.0.2",
|
|
63
67
|
"@glint/environment-ember-loose": "^1.0.2",
|
|
64
68
|
"@glint/template": "^1.0.2",
|
|
65
|
-
"@
|
|
66
|
-
"@
|
|
67
|
-
"@types/
|
|
68
|
-
"@types/
|
|
69
|
-
"@types/
|
|
70
|
-
"@types/
|
|
71
|
-
"@types/
|
|
72
|
-
"@
|
|
73
|
-
"@typescript-eslint/
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"ember-template-lint
|
|
77
|
-
"
|
|
78
|
-
"eslint
|
|
79
|
-
"eslint-
|
|
80
|
-
"eslint-plugin-
|
|
81
|
-
"eslint-plugin-
|
|
69
|
+
"@rollup/plugin-babel": "^6.0.3",
|
|
70
|
+
"@tsconfig/ember": "^3.0.0",
|
|
71
|
+
"@types/ember__component": "^4.0.14",
|
|
72
|
+
"@types/ember__destroyable": "^4.0.2",
|
|
73
|
+
"@types/ember__object": "^4.0.6",
|
|
74
|
+
"@types/ember__owner": "^4.0.4",
|
|
75
|
+
"@types/ember__runloop": "^4.0.4",
|
|
76
|
+
"@types/ember__service": "^4.0.3",
|
|
77
|
+
"@typescript-eslint/eslint-plugin": "^6.2.1",
|
|
78
|
+
"@typescript-eslint/parser": "^6.2.1",
|
|
79
|
+
"concurrently": "^8.2.0",
|
|
80
|
+
"ember-template-lint": "^5.11.1",
|
|
81
|
+
"ember-template-lint-plugin-prettier": "^5.0.0",
|
|
82
|
+
"eslint": "^8.46.0",
|
|
83
|
+
"eslint-config-prettier": "^8.9.0",
|
|
84
|
+
"eslint-plugin-ember": "^11.10.0",
|
|
85
|
+
"eslint-plugin-n": "^16.0.1",
|
|
86
|
+
"eslint-plugin-prettier": "^5.0.0",
|
|
82
87
|
"eslint-plugin-simple-import-sort": "^10.0.0",
|
|
83
88
|
"eslint-plugin-typescript-sort-keys": "^2.3.0",
|
|
84
|
-
"prettier": "^
|
|
85
|
-
"rollup": "^3.
|
|
89
|
+
"prettier": "^3.0.0",
|
|
90
|
+
"rollup": "^3.27.0",
|
|
86
91
|
"rollup-plugin-copy": "^3.4.0",
|
|
87
|
-
"
|
|
88
|
-
"typescript": "^5.1.3"
|
|
92
|
+
"typescript": "^5.1.6"
|
|
89
93
|
},
|
|
90
94
|
"engines": {
|
|
91
95
|
"node": "16.* || >= 18"
|
|
@@ -106,7 +110,9 @@
|
|
|
106
110
|
"version": 2
|
|
107
111
|
},
|
|
108
112
|
"scripts": {
|
|
109
|
-
"build": "
|
|
113
|
+
"build": "concurrently \"npm:build:*\" --names \"build:\"",
|
|
114
|
+
"build:js": "rollup --config",
|
|
115
|
+
"build:types": "glint --declaration",
|
|
110
116
|
"lint": "concurrently \"npm:lint:*(!fix)\" --names \"lint:\"",
|
|
111
117
|
"lint:fix": "concurrently \"npm:lint:*:fix\" --names \"fix:\"",
|
|
112
118
|
"lint:hbs": "ember-template-lint .",
|
|
@@ -114,7 +120,9 @@
|
|
|
114
120
|
"lint:js": "eslint . --cache",
|
|
115
121
|
"lint:js:fix": "eslint . --fix",
|
|
116
122
|
"lint:types": "glint",
|
|
117
|
-
"start": "
|
|
123
|
+
"start": "concurrently \"npm:start:*\" --names \"start:\"",
|
|
124
|
+
"start:js": "rollup --config --watch --no-watch.clearScreen",
|
|
125
|
+
"start:types": "glint --declaration --watch",
|
|
118
126
|
"test": "echo 'A v2 addon does not have tests, run tests in test-app'"
|
|
119
127
|
}
|
|
120
128
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"applyDecoratedDescriptor-fa858ac4.js","sources":["../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/initializerDefineProperty.js","../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/typeof.js","../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/toPrimitive.js","../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js","../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../../node_modules/.pnpm/@babel+runtime@7.22.3/node_modules/@babel/runtime/helpers/esm/applyDecoratedDescriptor.js"],"sourcesContent":["export default function _initializerDefineProperty(target, property, descriptor, context) {\n if (!descriptor) return;\n Object.defineProperty(target, property, {\n enumerable: descriptor.enumerable,\n configurable: descriptor.configurable,\n writable: descriptor.writable,\n value: descriptor.initializer ? descriptor.initializer.call(context) : void 0\n });\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof(obj);\n}","import _typeof from \"./typeof.js\";\nexport default function _toPrimitive(input, hint) {\n if (_typeof(input) !== \"object\" || input === null) return input;\n var prim = input[Symbol.toPrimitive];\n if (prim !== undefined) {\n var res = prim.call(input, hint || \"default\");\n if (_typeof(res) !== \"object\") return res;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (hint === \"string\" ? String : Number)(input);\n}","import _typeof from \"./typeof.js\";\nimport toPrimitive from \"./toPrimitive.js\";\nexport default function _toPropertyKey(arg) {\n var key = toPrimitive(arg, \"string\");\n return _typeof(key) === \"symbol\" ? key : String(key);\n}","import toPropertyKey from \"./toPropertyKey.js\";\nexport default function _defineProperty(obj, key, value) {\n key = toPropertyKey(key);\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n}","export default function _applyDecoratedDescriptor(target, property, decorators, descriptor, context) {\n var desc = {};\n Object.keys(descriptor).forEach(function (key) {\n desc[key] = descriptor[key];\n });\n desc.enumerable = !!desc.enumerable;\n desc.configurable = !!desc.configurable;\n if ('value' in desc || desc.initializer) {\n desc.writable = true;\n }\n desc = decorators.slice().reverse().reduce(function (desc, decorator) {\n return decorator(target, property, desc) || desc;\n }, desc);\n if (context && desc.initializer !== void 0) {\n desc.value = desc.initializer ? desc.initializer.call(context) : void 0;\n desc.initializer = undefined;\n }\n if (desc.initializer === void 0) {\n Object.defineProperty(target, property, desc);\n desc = null;\n }\n return desc;\n}"],"names":["_initializerDefineProperty","target","property","descriptor","context","Object","defineProperty","enumerable","configurable","writable","value","initializer","call","_typeof","obj","Symbol","iterator","constructor","prototype","_toPrimitive","input","hint","prim","toPrimitive","undefined","res","TypeError","String","Number","_toPropertyKey","arg","key","_defineProperty","toPropertyKey","_applyDecoratedDescriptor","decorators","desc","keys","forEach","slice","reverse","reduce","decorator"],"mappings":"AAAe,SAASA,0BAA0BA,CAACC,MAAM,EAAEC,QAAQ,EAAEC,UAAU,EAAEC,OAAO,EAAE;EACxF,IAAI,CAACD,UAAU,EAAE,OAAA;AACjBE,EAAAA,MAAM,CAACC,cAAc,CAACL,MAAM,EAAEC,QAAQ,EAAE;IACtCK,UAAU,EAAEJ,UAAU,CAACI,UAAU;IACjCC,YAAY,EAAEL,UAAU,CAACK,YAAY;IACrCC,QAAQ,EAAEN,UAAU,CAACM,QAAQ;AAC7BC,IAAAA,KAAK,EAAEP,UAAU,CAACQ,WAAW,GAAGR,UAAU,CAACQ,WAAW,CAACC,IAAI,CAACR,OAAO,CAAC,GAAG,KAAK,CAAA;AAC9E,GAAC,CAAC,CAAA;AACJ;;ACRe,SAASS,OAAOA,CAACC,GAAG,EAAE;EACnC,yBAAyB,CAAA;;AAEzB,EAAA,OAAOD,OAAO,GAAG,UAAU,IAAI,OAAOE,MAAM,IAAI,QAAQ,IAAI,OAAOA,MAAM,CAACC,QAAQ,GAAG,UAAUF,GAAG,EAAE;AAClG,IAAA,OAAO,OAAOA,GAAG,CAAA;GAClB,GAAG,UAAUA,GAAG,EAAE;IACjB,OAAOA,GAAG,IAAI,UAAU,IAAI,OAAOC,MAAM,IAAID,GAAG,CAACG,WAAW,KAAKF,MAAM,IAAID,GAAG,KAAKC,MAAM,CAACG,SAAS,GAAG,QAAQ,GAAG,OAAOJ,GAAG,CAAA;AAC7H,GAAC,EAAED,OAAO,CAACC,GAAG,CAAC,CAAA;AACjB;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a,SAAS,CAAA;AAC9B,GAAA;AACA,EAAA,IAAIY,IAAI,CAACzB,WAAW,KAAK,KAAK,CAAC,EAAE;IAC/BN,MAAM,CAACC,cAAc,CAACL,MAAM,EAAEC,QAAQ,EAAEkC,IAAI,CAAC,CAAA;AAC7CA,IAAAA,IAAI,GAAG,IAAI,CAAA;AACb,GAAA;AACA,EAAA,OAAOA,IAAI,CAAA;AACb;;;;","x_google_ignoreList":[0,1,2,3,4,5]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"components/container-query.d.ts","sourceRoot":"","sources":["../src/components/container-query.ts"],"names":[],"mappings":"AAGA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAG3C,OAAO,+DAKN,wCAAqC;AAEtC,UAAU,uBAAuB,CAAC,CAAC,SAAS,uBAAuB;IACjE,IAAI,EAAE;QACJ,mBAAmB,CAAC,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;QACvB,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,CAAC;IACF,MAAM,EAAE;QACN,OAAO,EAAE;YACP;gBACE,UAAU,CAAC,EAAE,UAAU,CAAC;gBACxB,QAAQ,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;aAC5B;SACF,CAAC;KACH,CAAC;IACF,OAAO,EAAE,WAAW,CAAC;CACtB;AAED,cAAqB,uBAAuB,CAC1C,CAAC,SAAS,uBAAuB,CACjC,SAAQ,SAAS,CAAC,uBAAuB,CAAC,CAAC,CAAC,CAAC;IACpC,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,YAAY,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;IAGxC,OAAO,SAA8B;IAE7B,WAAW,CAAC,EAClB,UAAU,EACV,YAAY,GACb,EAAE;QACD,UAAU,EAAE,UAAU,CAAC;QACvB,YAAY,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;KAC/B,GAAG,IAAI;CAIT"}
|
package/dist/index.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export { default as ContainerQuery } from "./components/container-query.js";
|
|
2
|
-
export { default as aspectRatio } from "./helpers/aspect-ratio.js";
|
|
3
|
-
export { default as height } from "./helpers/height.js";
|
|
4
|
-
export { default as width } from "./helpers/width.js";
|
|
5
|
-
export type { Dimensions, Features, IndexSignatureParameter, Metadata, QueryResults } from "./modifiers/container-query.js";
|
|
6
|
-
export { default as containerQuery } from "./modifiers/container-query.js";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import ContainerQueryComponent from "./components/container-query.js";
|
|
2
|
-
import AspectRatioHelper from "./helpers/aspect-ratio.js";
|
|
3
|
-
import HeightHelper from "./helpers/height.js";
|
|
4
|
-
import WidthHelper from "./helpers/width.js";
|
|
5
|
-
import ContainerQueryModifier from "./modifiers/container-query.js";
|
|
6
|
-
interface EmberContainerQueryRegistry {
|
|
7
|
-
ContainerQuery: typeof ContainerQueryComponent;
|
|
8
|
-
'aspect-ratio': typeof AspectRatioHelper;
|
|
9
|
-
'container-query': typeof ContainerQueryModifier;
|
|
10
|
-
height: typeof HeightHelper;
|
|
11
|
-
width: typeof WidthHelper;
|
|
12
|
-
}
|
|
13
|
-
export { EmberContainerQueryRegistry as default };
|