@xaendar/core 0.3.31 → 0.3.33

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xaendar/core",
3
- "version": "0.3.31",
3
+ "version": "0.3.33",
4
4
  "description": "A library containing core utils such as webcomponent base classes and theming support",
5
5
  "sideEffects": false,
6
6
  "type": "module",
@@ -16,6 +16,7 @@
16
16
  }
17
17
  },
18
18
  "dependencies": {
19
- "@xaendar/types": "0.3.31"
19
+ "@xaendar/signals": "0.3.33",
20
+ "@xaendar/types": "0.3.33"
20
21
  }
21
22
  }
@@ -2,6 +2,7 @@ import { AccessorDecorator } from '@xaendar/types';
2
2
  import { Beautify } from '@xaendar/types';
3
3
  import { ClassDecorator as ClassDecorator_2 } from '@xaendar/types';
4
4
  import { RequireOne } from '@xaendar/types';
5
+ import { SignalEqual } from '@xaendar/signals';
5
6
  import { VoidFunction as VoidFunction_2 } from '@xaendar/types';
6
7
 
7
8
  /**
@@ -70,9 +71,15 @@ export declare type Output<Value = void> = {
70
71
  emit: VoidFunction_2<Value extends void ? ([EventParams] | []) : ([Value, EventParams] | [Value])>;
71
72
  };
72
73
 
73
- export declare function Property<Class extends BaseWebComponent, Field>(params?: PropertyDecoratorParams): AccessorDecorator<Class, Field>;
74
+ export declare function Property<Class extends BaseWebComponent, Value, ActualValue = Value>(params?: PropertyDecoratorOptions<Value, ActualValue>): (_target: undefined, context: ClassFieldDecoratorContext<Class, Value>) => void;
74
75
 
75
- export declare type PropertyDecoratorParams = {
76
+ export declare type PropertyDecoratorOptions<Value, ActualValue = Value> = {
77
+ alias?: string;
78
+ equals?: SignalEqual<Value>;
79
+ transform?: (value: Value) => ActualValue;
80
+ };
81
+
82
+ export declare type PropertyDecoratorOptionsWithRequired<Value, ActualValue = Value> = PropertyDecoratorOptions<Value, ActualValue> & {
76
83
  required: true;
77
84
  };
78
85
 
@@ -27,22 +27,10 @@ var n = "⛔observedAttributes";
27
27
  //#region ../packages/core/src/decorators/property.decorator.ts
28
28
  function r(e) {
29
29
  return function(e, t) {
30
- if (typeof t.name == "symbol") throw Error("Symbol properties are not supported by the @Property decorator");
31
30
  let r = t.name;
32
- t.metadata[n] ??= [], t.metadata[n].push(r);
33
- let i = `⛔${r}`;
34
- return {
35
- get() {
36
- return this[i].get();
37
- },
38
- set(e) {
39
- this[i].set(e);
40
- },
41
- init(e) {
42
- let t = this;
43
- return t[i] = new Signal.State(e), e;
44
- }
45
- };
31
+ if (typeof r == "symbol") throw Error("Symbol properties are not supported");
32
+ let i = t.metadata;
33
+ i[n] ??= [], i[n].push(r);
46
34
  };
47
35
  }
48
36
  //#endregion
@@ -72,7 +60,9 @@ var s = class extends HTMLElement {
72
60
  _render() {}
73
61
  attributeChangedCallback(e, t, n) {
74
62
  let r = this;
75
- r[e] = n;
63
+ if (!(e in r)) throw Error(`Attribute ${e} is not associated to any property`);
64
+ if (!(r[e] instanceof Signal.State)) throw Error(`Property ${e} is not a Signal.State`);
65
+ r[e].set(n);
76
66
  }
77
67
  connectedCallback() {
78
68
  this._render();
@@ -1 +1 @@
1
- {"version":3,"file":"xaendar-core.es.js","names":[],"sources":["../../../packages/core/src/decorators/event.decorator.ts","../../../packages/core/src/costants.ts","../../../packages/core/src/decorators/property.decorator.ts","../../../packages/core/src/decorators/web-component/web-component.decorator.ts","../../../packages/core/src/directives/base-web-component.ts"],"sourcesContent":["import { AccessorDecorator, ClassAccessorDecoratorValue } from '@xaendar/types';\r\nimport { BaseWebComponent } from '../directives/base-web-component';\r\nimport { EventParams } from '../types/event/event-params.type';\r\nimport { Output } from '../types/event/output.type';\r\n\r\nfunction isEventParams(value: EventParams | unknown): value is EventParams {\r\n return !!value && typeof value === 'object' && ('bubbles' in value || 'cancelable' in value || 'composed' in value);\r\n}\r\n\r\nexport function Event<\r\n Class extends BaseWebComponent,\r\n Field,\r\n Data = void,\r\n>(params?: EventParams): AccessorDecorator<Class, Field, Output<Data>> {\r\n return (_value: ClassAccessorDecoratorValue<Field>, context: ClassAccessorDecoratorContext<Class, Output<Data>>): ReturnType<AccessorDecorator<Class, Field, Output<Data>>> => {\r\n const output: Output<Data> = {\r\n emit: (_valueOrOverrideParams?: Data | EventParams, _overrideParams?: EventParams) => { }\r\n };\r\n\r\n return {\r\n get(): Output<Data> {\r\n output.emit = function(this: Class, valueOrOverrideParams?: Data | EventParams, overrideParams?: EventParams) {\r\n let eventParams: CustomEventInit<Data> = {};\r\n\r\n eventParams = isEventParams(valueOrOverrideParams)\r\n ? { ...params, ...valueOrOverrideParams } \r\n : { ...params, ...overrideParams, detail: valueOrOverrideParams }\r\n\r\n const event = new CustomEvent(context.name as string, eventParams);\r\n const classInstance = this;\r\n classInstance.dispatchEvent(event);\r\n };\r\n return output;\r\n }\r\n }\r\n }\r\n }","export const INTERNAL_PREFIX = '⛔';\r\nexport const INTERNAL_OBSERVED_ATTRIBUTES = `${INTERNAL_PREFIX}observedAttributes`;","import { AccessorDecorator, ClassAccessorDecoratorValue } from '@xaendar/types';\r\nimport { INTERNAL_OBSERVED_ATTRIBUTES, INTERNAL_PREFIX } from '../costants';\r\nimport { BaseWebComponent } from '../directives/base-web-component';\r\nimport { PropertyDecoratorParams } from '../types/property-decorator-params.type';\r\n\r\nexport function Property<\r\n Class extends BaseWebComponent,\r\n Field\r\n >(params?: PropertyDecoratorParams): AccessorDecorator<Class, Field> {\r\n return function (_value: ClassAccessorDecoratorValue<Field>, context: ClassAccessorDecoratorContext<Class, Field>): ReturnType<AccessorDecorator<Class, Field>> {\r\n if (typeof context.name === 'symbol') {\r\n throw new Error('Symbol properties are not supported by the @Property decorator');\r\n }\r\n \r\n const propertyKey = context.name;\r\n context.metadata![INTERNAL_OBSERVED_ATTRIBUTES] ??= new Array<string>;\r\n (context.metadata![INTERNAL_OBSERVED_ATTRIBUTES] as string[]).push(propertyKey);\r\n \r\n const internalPropertyKey = `${INTERNAL_PREFIX}${propertyKey}`\r\n \r\n return {\r\n get() {\r\n const classInstance = (this as BaseWebComponent & Record<typeof internalPropertyKey, Signal.State<Field>>);\r\n return classInstance[internalPropertyKey]!.get();\r\n },\r\n set(value: Field) {\r\n const classInstance = (this as BaseWebComponent & Record<typeof internalPropertyKey, Signal.State<Field>>);\r\n classInstance[internalPropertyKey]!.set(value);\r\n },\r\n init(initialValue: Field) {\r\n const classInstance = (this as BaseWebComponent & Record<typeof internalPropertyKey, Signal.State<Field>>);\r\n classInstance[internalPropertyKey] = new Signal.State(initialValue);\r\n return initialValue;\r\n }\r\n };\r\n }\r\n}\r\n","import { ClassDecorator, Constructor } from '@xaendar/types';\r\nimport { INTERNAL_OBSERVED_ATTRIBUTES } from '../../costants';\r\nimport { BaseWebComponent } from '../../directives/base-web-component';\r\nimport { WebComponentDecoratorParams } from '../../types/web-component-decorator-params.type';\r\n\r\n/**\r\n * Decorator to define a web component\r\n * @param selector Name or names of the custom element\r\n */\r\nexport function WebComponent<T extends BaseWebComponent>(options: WebComponentDecoratorParams): ClassDecorator<T> {\r\n return function (klass: Constructor<T>, context: ClassDecoratorContext<Constructor<T>>): void {\r\n defineObservedAttributes(klass, context);\r\n setSelectors(klass, options.selector);\r\n };\r\n}\r\n\r\n/**\r\n * Function to define the observedAttributes static property on the class.\r\n * We define static get observedAttributes programmatically\r\n * to abstract the manual definition from the user.\r\n *\r\n * We could not define the property in the base class due to the fact\r\n * that is static and each derived class would override the value of the others\r\n * @param klass The class to set the observedAttributes on\r\n * @param attributes The attributes to observe\r\n */\r\nfunction defineObservedAttributes<T extends BaseWebComponent>(klass: Constructor<T>, context: ClassDecoratorContext<Constructor<T>>): void {\r\n Object.defineProperty(klass, 'observedAttributes', {\r\n get: () => context.metadata![INTERNAL_OBSERVED_ATTRIBUTES],\r\n configurable: false,\r\n enumerable: false\r\n });\r\n}\r\n\r\n/**\r\n * Function to add the custom element definition to the browser using the passed selectors.\r\n * @param klass The class to define as a web component\r\n * @param selectors The selector or selectors to reference the web component in HTML\r\n */\r\nfunction setSelectors<T extends BaseWebComponent>(klass: Constructor<T>, selectors: string | string[]): void {\r\n Array.isArray(selectors)\r\n ? selectors.forEach(selector => customElements.define(selector, klass))\r\n : customElements.define(selectors, klass);\r\n}","/**\r\n * Base class for all Web Components in the framework\r\n * \r\n * This class internally has an `observedAttributes` property\r\n * add programmaticaly by the @WebComponent decorator. \r\n * It won't appear by intellisense but it's there.\r\n */\r\nexport class BaseWebComponent extends HTMLElement {\r\n /**\r\n * The root of the Web Component, where the content is rendered\r\n */\r\n private readonly _root: ShadowRoot;\r\n\r\n constructor() {\r\n super();\r\n this._root = this.attachShadow({ mode: 'open' });\r\n }\r\n\r\n /**\r\n * Method called by the @Property decorator to\r\n * update the rendering of the component\r\n * @internal \r\n */\r\n private _render(): void { }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when an attribute\r\n * on the host element is changed\r\n * \r\n * This method runs before the connectedCallback method if any observed attribute\r\n * is specified on the CustomElement tag in the HTML\r\n * \r\n * @param name Name of the attribute changed\r\n * @param _oldValue Old value of the attribute\r\n * @param newValue New value of the attribute\r\n */\r\n private attributeChangedCallback(name: string, _oldValue: unknown, newValue: unknown): void {\r\n /*\r\n Since the 'Property Decorator add the property key to the ObservedAttributes\r\n We are sure that the property with the given name exists on the instance of the subclass\r\n */\r\n const context = this as BaseWebComponent & Record<string, unknown>;\r\n context[name] = newValue;\r\n }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when a CustomElement\r\n * is added to the DOM\r\n * \r\n * This method is called EVERY time the element is added\r\n */\r\n private connectedCallback(): void {\r\n this._render();\r\n }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when a CustomElement\r\n * is removed from the DOM\r\n * \r\n * This method is called EVERY time the element is removed\r\n * \r\n * We use this method to reset the _initialized flag\r\n * so that if the element is re-added to the DOM\r\n * the properties initialization won't call the render method\r\n */\r\n private disconnectedCallback(): void {\r\n }\r\n}"],"mappings":";AAKA,SAAS,EAAc,GAAoD;CAC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EACjD,WAAW,EAAQ,SAAU;EAC7B,cAAc;EACd,YAAY;CACd,CAAC;AACH;AAOA,SAAS,EAAyC,GAAuB,GAAoC;CAC3G,MAAM,QAAQ,CAAS,IACnB,EAAU,SAAQ,MAAY,eAAe,OAAO,GAAU,CAAK,CAAC,IACpE,eAAe,OAAO,GAAW,CAAK;AAC5C;;;ACpCA,IAAa,IAAb,cAAsC,YAAY;CAIhD;CAEA,cAAc;EAEZ,AADA,MAAM,GACN,KAAK,QAAQ,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;CACjD;CAOA,UAAwB,CAAE;CAa1B,yBAAiC,GAAc,GAAoB,GAAyB;EAK1F,IAAM,IAAU;EAChB,EAAQ,KAAQ;CAClB;CAQA,oBAAkC;EAChC,KAAK,QAAQ;CACf;CAYA,uBAAqC,CACrC;AACF"}
1
+ {"version":3,"file":"xaendar-core.es.js","names":[],"sources":["../../../packages/core/src/decorators/event.decorator.ts","../../../packages/core/src/costants.ts","../../../packages/core/src/decorators/property.decorator.ts","../../../packages/core/src/decorators/web-component/web-component.decorator.ts","../../../packages/core/src/directives/base-web-component.ts"],"sourcesContent":["import { AccessorDecorator, ClassAccessorDecoratorValue } from '@xaendar/types';\r\nimport { BaseWebComponent } from '../directives/base-web-component';\r\nimport { EventParams } from '../types/event/event-params.type';\r\nimport { Output } from '../types/event/output.type';\r\n\r\nfunction isEventParams(value: EventParams | unknown): value is EventParams {\r\n return !!value && typeof value === 'object' && ('bubbles' in value || 'cancelable' in value || 'composed' in value);\r\n}\r\n\r\nexport function Event<\r\n Class extends BaseWebComponent,\r\n Field,\r\n Data = void,\r\n>(params?: EventParams): AccessorDecorator<Class, Field, Output<Data>> {\r\n return (_value: ClassAccessorDecoratorValue<Field>, context: ClassAccessorDecoratorContext<Class, Output<Data>>): ReturnType<AccessorDecorator<Class, Field, Output<Data>>> => {\r\n const output: Output<Data> = {\r\n emit: (_valueOrOverrideParams?: Data | EventParams, _overrideParams?: EventParams) => { }\r\n };\r\n\r\n return {\r\n get(): Output<Data> {\r\n output.emit = function(this: Class, valueOrOverrideParams?: Data | EventParams, overrideParams?: EventParams) {\r\n let eventParams: CustomEventInit<Data> = {};\r\n\r\n eventParams = isEventParams(valueOrOverrideParams)\r\n ? { ...params, ...valueOrOverrideParams } \r\n : { ...params, ...overrideParams, detail: valueOrOverrideParams }\r\n\r\n const event = new CustomEvent(context.name as string, eventParams);\r\n const classInstance = this;\r\n classInstance.dispatchEvent(event);\r\n };\r\n return output;\r\n }\r\n }\r\n }\r\n }","export const INTERNAL_PREFIX = '⛔';\r\nexport const INTERNAL_OBSERVED_ATTRIBUTES = `${INTERNAL_PREFIX}observedAttributes`;","import { INTERNAL_OBSERVED_ATTRIBUTES } from '../costants';\r\nimport { BaseWebComponent } from '../directives/base-web-component';\r\nimport { PropertyDecoratorOptions } from '../types/property-decorator-params.type';\r\n\r\nexport function Property<Class extends BaseWebComponent, Value, ActualValue = Value>(params?: PropertyDecoratorOptions<Value, ActualValue>) {\r\n return function (_target: undefined, context: ClassFieldDecoratorContext<Class, Value>): void {\r\n const propertyKey = context.name;\r\n\r\n if (typeof propertyKey === 'symbol') {\r\n throw new Error('Symbol properties are not supported');\r\n }\r\n\r\n const metadata = context.metadata as { [INTERNAL_OBSERVED_ATTRIBUTES]?: string[] };\r\n metadata[INTERNAL_OBSERVED_ATTRIBUTES] ??= [];\r\n metadata[INTERNAL_OBSERVED_ATTRIBUTES].push(propertyKey);\r\n };\r\n}","import { ClassDecorator, Constructor } from '@xaendar/types';\r\nimport { INTERNAL_OBSERVED_ATTRIBUTES } from '../../costants';\r\nimport { BaseWebComponent } from '../../directives/base-web-component';\r\nimport { WebComponentDecoratorParams } from '../../types/web-component-decorator-params.type';\r\n\r\n/**\r\n * Decorator to define a web component\r\n * @param selector Name or names of the custom element\r\n */\r\nexport function WebComponent<T extends BaseWebComponent>(options: WebComponentDecoratorParams): ClassDecorator<T> {\r\n return function (klass: Constructor<T>, context: ClassDecoratorContext<Constructor<T>>): void {\r\n defineObservedAttributes(klass, context);\r\n setSelectors(klass, options.selector);\r\n };\r\n}\r\n\r\n/**\r\n * Function to define the observedAttributes static property on the class.\r\n * We define static get observedAttributes programmatically\r\n * to abstract the manual definition from the user.\r\n *\r\n * We could not define the property in the base class due to the fact\r\n * that is static and each derived class would override the value of the others\r\n * @param klass The class to set the observedAttributes on\r\n * @param attributes The attributes to observe\r\n */\r\nfunction defineObservedAttributes<T extends BaseWebComponent>(klass: Constructor<T>, context: ClassDecoratorContext<Constructor<T>>): void {\r\n Object.defineProperty(klass, 'observedAttributes', {\r\n get: () => context.metadata![INTERNAL_OBSERVED_ATTRIBUTES],\r\n configurable: false,\r\n enumerable: false\r\n });\r\n}\r\n\r\n/**\r\n * Function to add the custom element definition to the browser using the passed selectors.\r\n * @param klass The class to define as a web component\r\n * @param selectors The selector or selectors to reference the web component in HTML\r\n */\r\nfunction setSelectors<T extends BaseWebComponent>(klass: Constructor<T>, selectors: string | string[]): void {\r\n Array.isArray(selectors)\r\n ? selectors.forEach(selector => customElements.define(selector, klass))\r\n : customElements.define(selectors, klass);\r\n}","/**\r\n * Base class for all Web Components in the framework\r\n * \r\n * This class internally has an `observedAttributes` property\r\n * add programmaticaly by the @WebComponent decorator. \r\n * It won't appear by intellisense but it's there.\r\n */\r\nexport class BaseWebComponent extends HTMLElement {\r\n /**\r\n * The root of the Web Component, where the content is rendered\r\n */\r\n private readonly _root: ShadowRoot;\r\n\r\n constructor() {\r\n super();\r\n this._root = this.attachShadow({ mode: 'open' });\r\n }\r\n\r\n /**\r\n * Method called by the @Property decorator to\r\n * update the rendering of the component\r\n * @internal \r\n */\r\n private _render(): void { }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when an attribute\r\n * on the host element is changed\r\n * \r\n * This method runs before the connectedCallback method if any observed attribute\r\n * is specified on the CustomElement tag in the HTML\r\n * \r\n * @param name Name of the attribute changed\r\n * @param _oldValue Old value of the attribute\r\n * @param newValue New value of the attribute\r\n */\r\n private attributeChangedCallback(name: string, _oldValue: unknown, newValue: unknown): void {\r\n /*\r\n Since the 'Property Decorator add the property key to the ObservedAttributes\r\n We are sure that the property with the given name exists on the instance of the subclass\r\n */\r\n const context = this as BaseWebComponent & Record<string, unknown>;\r\n if (!(name in context)) {\r\n throw new Error(`Attribute ${name} is not associated to any property`);\r\n }\r\n\r\n if (!(context[name] instanceof Signal.State)) {\r\n throw new Error(`Property ${name} is not a Signal.State`);\r\n }\r\n\r\n context[name].set(newValue);\r\n }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when a CustomElement\r\n * is added to the DOM\r\n * \r\n * This method is called EVERY time the element is added\r\n */\r\n private connectedCallback(): void {\r\n this._render();\r\n }\r\n\r\n /**\r\n * Method automatically called by the JavascriptEngine when a CustomElement\r\n * is removed from the DOM\r\n * \r\n * This method is called EVERY time the element is removed\r\n * \r\n * We use this method to reset the _initialized flag\r\n * so that if the element is re-added to the DOM\r\n * the properties initialization won't call the render method\r\n */\r\n private disconnectedCallback(): void {\r\n }\r\n}"],"mappings":";AAKA,SAAS,EAAc,GAAoD;CACzE,OAAO,CAAC,CAAC,KAAS,OAAO,KAAU,aAAa,aAAa,KAAS,gBAAgB,KAAS,cAAc;AAC/G;AAEA,SAAgB,EAId,GAAqE;CACrE,QAAQ,GAA4C,MAA2H;EAC7K,IAAM,IAAuB,EAC3B,OAAO,GAA6C,MAAkC,CAAE,EACzF;EAED,OAAO,EACL,MAAoB;GAYhB,OAXF,EAAO,OAAO,SAAsB,GAA4C,GAA8B;IAC5G,IAAI,IAAqC,CAAC;IAExC,IAAc,EAAc,CAAqB,IAC7C;KAAE,GAAG;KAAQ,GAAG;IAAsB,IACtC;KAAE,GAAG;KAAQ,GAAG;KAAgB,QAAQ;IAAsB;IAElE,IAAM,IAAQ,IAAI,YAAY,EAAQ,MAAgB,CAAW;IAEjE,KAAc,cAAc,CAAK;GACnC,GACO;EACT,EACF;CACF;AACF;ACnCF,IAAa,IAA+B;;;ACG5C,SAAgB,EAA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