@meonode/ui 0.2.20 → 0.2.22
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/CHANGELOG.md +27 -0
- package/dist/components/styled-renderer.client.d.ts +1 -3
- package/dist/components/styled-renderer.client.d.ts.map +1 -1
- package/dist/components/styled-renderer.client.js +1 -1
- package/dist/core.node.d.ts +18 -30
- package/dist/core.node.d.ts.map +1 -1
- package/dist/core.node.js +47 -63
- package/dist/hoc/component.hoc.d.ts.map +1 -1
- package/dist/hoc/component.hoc.js +2 -2
- package/dist/node.type.d.ts +10 -4
- package/dist/node.type.d.ts.map +1 -1
- package/package.json +9 -9
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,33 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.2.22] - 2025-09-29
|
|
9
|
+
|
|
10
|
+
### Refactor
|
|
11
|
+
|
|
12
|
+
- **refactor(core)**: Refactor key and CSS prop handling for improved rendering
|
|
13
|
+
- Removed manual key generation logic, relying on React's reconciliation for array children.
|
|
14
|
+
- Streamlined CSS prop handling within `BaseNode` and `StyledRenderer` for better integration with styling solutions.
|
|
15
|
+
- Updated `createElement` calls to correctly spread children, supporting both single and array children.
|
|
16
|
+
|
|
17
|
+
## [0.2.21] - 2025-09-23
|
|
18
|
+
|
|
19
|
+
### Refactor
|
|
20
|
+
|
|
21
|
+
- **refactor(core):** make node processing logic static and robust
|
|
22
|
+
|
|
23
|
+
### Added
|
|
24
|
+
|
|
25
|
+
- **feat:** update NodeFunction type to improve dynamic node content generation and update FunctionRendererProps interface to use NodeFunction
|
|
26
|
+
|
|
27
|
+
### Fixed
|
|
28
|
+
|
|
29
|
+
- **fix(component.hoc.ts):** enhance node instance check in Renderer for improved stability
|
|
30
|
+
- **fix(node.type.ts):** remove unused processRawNode property from Node type
|
|
31
|
+
|
|
32
|
+
### Changed
|
|
33
|
+
- **package:** update dependencies to latest versions
|
|
34
|
+
|
|
8
35
|
## [0.2.20] - 2025-09-22
|
|
9
36
|
|
|
10
37
|
### Refactor
|
|
@@ -6,7 +6,5 @@ export interface StyledRendererProps<E extends NodeElement> {
|
|
|
6
6
|
children?: ReactNode;
|
|
7
7
|
css?: CSSInterpolation;
|
|
8
8
|
}
|
|
9
|
-
export default function StyledRenderer<E extends NodeElement, TProps extends Record<string, any>>({ element,
|
|
10
|
-
css: CSSInterpolation;
|
|
11
|
-
}, string | import("react").JSXElementConstructor<any>>;
|
|
9
|
+
export default function StyledRenderer<E extends NodeElement, TProps extends Record<string, any>>({ element, children, ...props }: StyledRendererProps<E> & TProps): import("react").ReactElement<Omit<StyledRendererProps<E> & TProps, "children" | "element">, string | import("react").JSXElementConstructor<any>>;
|
|
12
10
|
//# sourceMappingURL=styled-renderer.client.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styled-renderer.client.d.ts","sourceRoot":"","sources":["../../src/components/styled-renderer.client.ts"],"names":[],"mappings":"AAEA,OAAO,EAAY,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAEhD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAC1D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAEpD,MAAM,WAAW,mBAAmB,CAAC,CAAC,SAAS,WAAW;IACxD,OAAO,EAAE,CAAC,CAAA;IACV,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,GAAG,CAAC,EAAE,gBAAgB,CAAA;CACvB;AAED,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,CAAC,SAAS,WAAW,EAAE,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,EAChG,OAAO,EACP,
|
|
1
|
+
{"version":3,"file":"styled-renderer.client.d.ts","sourceRoot":"","sources":["../../src/components/styled-renderer.client.ts"],"names":[],"mappings":"AAEA,OAAO,EAAY,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAEhD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAC1D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAEpD,MAAM,WAAW,mBAAmB,CAAC,CAAC,SAAS,WAAW;IACxD,OAAO,EAAE,CAAC,CAAA;IACV,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,GAAG,CAAC,EAAE,gBAAgB,CAAA;CACvB;AAED,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,CAAC,SAAS,WAAW,EAAE,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,EAChG,OAAO,EACP,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,mBAAmB,CAAC,CAAC,CAAC,GAAG,MAAM,oJAEjC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";var _excluded=["element","
|
|
1
|
+
"use client";var _excluded=["element","children"];function _objectWithoutProperties(a,b){if(null==a)return{};var c,d,e=_objectWithoutPropertiesLoose(a,b);if(Object.getOwnPropertySymbols){var f=Object.getOwnPropertySymbols(a);for(d=0;d<f.length;d++)c=f[d],-1===b.indexOf(c)&&{}.propertyIsEnumerable.call(a,c)&&(e[c]=a[c])}return e}function _objectWithoutPropertiesLoose(a,b){if(null==a)return{};var c={};for(var d in a)if({}.hasOwnProperty.call(a,d)){if(-1!==b.indexOf(d))continue;c[d]=a[d]}return c}import{jsx}from"@emotion/react";export default function StyledRenderer(a){var b=a.element,c=a.children,d=_objectWithoutProperties(a,_excluded);return jsx(b,d,c)}StyledRenderer.displayName="Styled";
|
package/dist/core.node.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import type { Children, FinalNodeProps, HasRequiredProps, MergedProps,
|
|
1
|
+
import { type ReactElement } from 'react';
|
|
2
|
+
import type { Children, FinalNodeProps, HasRequiredProps, MergedProps, NodeElementType, NodeInstance, NodePortal, NodeProps, PropsOf, RawNodeProps } from './node.type.js';
|
|
3
3
|
/**
|
|
4
4
|
* Represents a node in a React component tree with theme and styling capabilities.
|
|
5
5
|
* This class wraps React elements and handles:
|
|
@@ -146,13 +146,18 @@ export declare class BaseNode<E extends NodeElementType> implements NodeInstance
|
|
|
146
146
|
* @private
|
|
147
147
|
* @static
|
|
148
148
|
*/
|
|
149
|
-
static _renderProcessedNode
|
|
149
|
+
private static _renderProcessedNode;
|
|
150
150
|
/**
|
|
151
|
-
*
|
|
152
|
-
* @param
|
|
151
|
+
* Renders this node into a `ReactNode`, handling function node element.
|
|
152
|
+
* @param node The node to render.
|
|
153
153
|
* @private
|
|
154
|
+
* @static
|
|
155
|
+
* @example
|
|
156
|
+
* ```typescript
|
|
157
|
+
* const myNode = Node('div', { children: [ () => 'Hello' ] });
|
|
158
|
+
* ```
|
|
154
159
|
*/
|
|
155
|
-
private _isFunctionChild;
|
|
160
|
+
private static _isFunctionChild;
|
|
156
161
|
/**
|
|
157
162
|
* Renders the output of a function-as-a-child, ensuring theme propagation.
|
|
158
163
|
*
|
|
@@ -162,26 +167,11 @@ export declare class BaseNode<E extends NodeElementType> implements NodeInstance
|
|
|
162
167
|
* @param props The properties for the function renderer.
|
|
163
168
|
* @param props.render The function to execute to get the child content.
|
|
164
169
|
* @param props.passedTheme The theme to propagate to the rendered child.
|
|
165
|
-
* @param props.processRawNode A reference to the `_processRawNode` method for recursive processing.
|
|
170
|
+
* // * @param props.processRawNode A reference to the `_processRawNode` method for recursive processing.
|
|
166
171
|
* @returns The rendered `ReactNode`.
|
|
167
172
|
* @private
|
|
168
173
|
*/
|
|
169
|
-
private _functionRenderer;
|
|
170
|
-
/**
|
|
171
|
-
* Generates a stable key for a node, especially for elements within an array.
|
|
172
|
-
*
|
|
173
|
-
* If an `existingKey` is provided, it is returned. Otherwise, a key is generated
|
|
174
|
-
* based on the element's type name and its index within a list of siblings.
|
|
175
|
-
* This helps prevent re-rendering issues in React when dealing with dynamic lists.
|
|
176
|
-
* @param options The options for key generation.
|
|
177
|
-
* @param options.nodeIndex The index of the node in an array of children.
|
|
178
|
-
* @param options.element The element for which to generate a key.
|
|
179
|
-
* @param options.existingKey An existing key, if one was already provided.
|
|
180
|
-
* @param options.children The children of the node, used to add complexity to the key.
|
|
181
|
-
* @returns A React key, or `undefined` if no key could be generated.
|
|
182
|
-
* @private
|
|
183
|
-
*/
|
|
184
|
-
private _generateKey;
|
|
174
|
+
private static _functionRenderer;
|
|
185
175
|
/**
|
|
186
176
|
* Processes a single raw node, recursively converting it into a `BaseNode` or other renderable type.
|
|
187
177
|
*
|
|
@@ -192,15 +182,13 @@ export declare class BaseNode<E extends NodeElementType> implements NodeInstance
|
|
|
192
182
|
* - **Valid React Elements**: Converts them into `BaseNode` instances, extracting props and propagating the theme.
|
|
193
183
|
* - **React Component Types**: Wraps them in a `BaseNode` with the parent theme.
|
|
194
184
|
* - **React Component Instances**: Renders them and processes the output recursively.
|
|
195
|
-
*
|
|
196
|
-
*
|
|
197
|
-
* @param rawNode The raw child node to process.
|
|
198
|
-
* @param parentTheme The theme inherited from the parent.
|
|
199
|
-
* @param nodeIndex The index of the child if it is in an array, used for key generation.
|
|
185
|
+
* @param node The raw child node to process.
|
|
186
|
+
* @param passedTheme The theme inherited from the parent.
|
|
200
187
|
* @returns A processed `NodeElement` (typically a `BaseNode` instance or a primitive).
|
|
201
188
|
* @private
|
|
189
|
+
* @static
|
|
202
190
|
*/
|
|
203
|
-
private _processRawNode;
|
|
191
|
+
private static _processRawNode;
|
|
204
192
|
/**
|
|
205
193
|
* Normalizes a processed child node into a final, renderable `ReactNode`.
|
|
206
194
|
*
|
|
@@ -224,7 +212,7 @@ export declare class BaseNode<E extends NodeElementType> implements NodeInstance
|
|
|
224
212
|
* 1. Validating that the node's `element` type is renderable.
|
|
225
213
|
* 2. Normalizing processed children into `ReactNode`s using `_normalizeChild`.
|
|
226
214
|
* 3. Caching normalized children to avoid re-processing on subsequent renders.
|
|
227
|
-
* 4. Assembling the final props, including `
|
|
215
|
+
* 4. Assembling the final props, including `style`, and other attributes.
|
|
228
216
|
* 5. If the element has a `css` prop, it may be wrapped in a `StyledRenderer` to handle
|
|
229
217
|
* CSS-in-JS styling.
|
|
230
218
|
* 6. Finally, calling `React.createElement` with the element, props, and children.
|
package/dist/core.node.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core.node.d.ts","sourceRoot":"","sources":["../src/core.node.ts"],"names":[],"mappings":"AACA,
|
|
1
|
+
{"version":3,"file":"core.node.d.ts","sourceRoot":"","sources":["../src/core.node.ts"],"names":[],"mappings":"AACA,OAAc,EAQZ,KAAK,YAAY,EAElB,MAAM,OAAO,CAAA;AACd,OAAO,KAAK,EACV,QAAQ,EACR,cAAc,EAEd,gBAAgB,EAChB,WAAW,EAEX,eAAe,EAEf,YAAY,EACZ,UAAU,EACV,SAAS,EACT,OAAO,EACP,YAAY,EAEb,MAAM,mBAAmB,CAAA;AAQ1B;;;;;;;;GAQG;AACH,qBAAa,QAAQ,CAAC,CAAC,SAAS,eAAe,CAAE,YAAW,YAAY,CAAC,CAAC,CAAC;IACzE,+EAA+E;IACxE,OAAO,EAAE,CAAC,CAAA;IACjB,kFAAkF;IAC3E,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAK;IACrC,0CAA0C;IAC1C,SAAgB,UAAU,UAAO;IAEjC,wFAAwF;IACxF,OAAO,CAAC,MAAM,CAAC,CAAgB;IAC/B,4CAA4C;IAC5C,OAAO,CAAC,iBAAiB,CAA8B;IACvD,+CAA+C;IAC/C,OAAO,CAAC,gBAAgB,CAA0E;IAClG,+DAA+D;IAC/D,OAAO,CAAC,aAAa,CAAC,CAAQ;IAC9B,oCAAoC;IACpC,OAAO,CAAC,mBAAmB,CAAC,CAAW;IACvC,mFAAmF;I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B,GACpG,gBAAgB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,IAAI,GACxC,CAAC,CAAC,eAAe,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EACjE,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,EAAE,eAAe,CAAC,EAAE,UAAU,CAAC,KACrD,YAAY,CAAC,CAAC,CAAC,CAAC,GAAG;IAAE,OAAO,EAAE,CAAC,CAAA;CAAE,GACtC,CAAC,CAAC,eAAe,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EACjE,QAAQ,CAAC,EAAE,QAAQ,EACnB,KAAK,CAAC,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,EAAE,eAAe,CAAC,EAAE,UAAU,CAAC,KACtD,YAAY,CAAC,CAAC,CAAC,CAAC,GAAG;IAAE,OAAO,EAAE,CAAC,CAAA;CAAE,CAQzC"}
|
package/dist/core.node.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var _excluded=["ref","key","children","nodetheme","theme","props"],_excluded2=["style"],_excluded3=["style","css"],_excluded4=["style"],_excluded5=["children","
|
|
1
|
+
"use strict";var _excluded=["ref","key","children","nodetheme","theme","props"],_excluded2=["style"],_excluded3=["style","css"],_excluded4=["style"],_excluded5=["children","css","nativeProps"];function _objectWithoutProperties(a,b){if(null==a)return{};var c,d,e=_objectWithoutPropertiesLoose(a,b);if(Object.getOwnPropertySymbols){var f=Object.getOwnPropertySymbols(a);for(d=0;d<f.length;d++)c=f[d],-1===b.indexOf(c)&&{}.propertyIsEnumerable.call(a,c)&&(e[c]=a[c])}return e}function _objectWithoutPropertiesLoose(a,b){if(null==a)return{};var c={};for(var d in a)if({}.hasOwnProperty.call(a,d)){if(-1!==b.indexOf(d))continue;c[d]=a[d]}return c}function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _defineProperty(a,b,c){return(b=_toPropertyKey(b))in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"==_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!=_typeof(a)||!a)return a;var c=a[Symbol.toPrimitive];if(void 0!==c){var d=c.call(a,b||"default");if("object"!=_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}import React,{createElement,Fragment,isValidElement}from"react";import{createStableHash,isNodeInstance,resolveDefaultStyle}from"./helper/node.helper.js";import{isForwardRef,isFragment,isMemo,isReactClassComponent,isValidElementType}from"./helper/react-is.helper.js";import{createRoot}from"react-dom/client";import{getComponentType,getCSSProps,getDOMProps,getElementTypeName,hasNoStyleTag,omit,omitUndefined}from"./helper/common.helper.js";import StyledRenderer from"./components/styled-renderer.client.js";import{resolveObjWithTheme}from"./helper/theme.helper.js";/**
|
|
2
2
|
* Represents a node in a React component tree with theme and styling capabilities.
|
|
3
3
|
* This class wraps React elements and handles:
|
|
4
4
|
* - Props processing and normalization
|
|
@@ -15,19 +15,6 @@
|
|
|
15
15
|
* @param element The React element or component type this node will represent.
|
|
16
16
|
* @param rawProps The initial, unprocessed props for the element.
|
|
17
17
|
*/constructor(a){var b=this,c=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{};/** The underlying React element or component type that this node represents *//** Original props passed during construction, preserved for cloning/recreation *//** Flag to identify BaseNode instances *//** DOM element used for portal rendering *//** React root instance for portal rendering *//**
|
|
18
|
-
* Generates a stable key for a node, especially for elements within an array.
|
|
19
|
-
*
|
|
20
|
-
* If an `existingKey` is provided, it is returned. Otherwise, a key is generated
|
|
21
|
-
* based on the element's type name and its index within a list of siblings.
|
|
22
|
-
* This helps prevent re-rendering issues in React when dealing with dynamic lists.
|
|
23
|
-
* @param options The options for key generation.
|
|
24
|
-
* @param options.nodeIndex The index of the node in an array of children.
|
|
25
|
-
* @param options.element The element for which to generate a key.
|
|
26
|
-
* @param options.existingKey An existing key, if one was already provided.
|
|
27
|
-
* @param options.children The children of the node, used to add complexity to the key.
|
|
28
|
-
* @returns A React key, or `undefined` if no key could be generated.
|
|
29
|
-
* @private
|
|
30
|
-
*//**
|
|
31
18
|
* Normalizes a processed child node into a final, renderable `ReactNode`.
|
|
32
19
|
*
|
|
33
20
|
* This method is called during the `render` phase. It takes a child that has already
|
|
@@ -40,7 +27,7 @@
|
|
|
40
27
|
* @returns A renderable `ReactNode`.
|
|
41
28
|
* @throws {Error} If the child is not a valid React element type.
|
|
42
29
|
* @private
|
|
43
|
-
*/_defineProperty(this,"rawProps",{}),_defineProperty(this,"isBaseNode",!0),_defineProperty(this,"_portalDOMElement",null),_defineProperty(this,"_portalReactRoot",null),_defineProperty(this,"
|
|
30
|
+
*/_defineProperty(this,"rawProps",{}),_defineProperty(this,"isBaseNode",!0),_defineProperty(this,"_portalDOMElement",null),_defineProperty(this,"_portalReactRoot",null),_defineProperty(this,"_normalizeChild",function(a){var c,d;// Handle null/undefined quickly
|
|
44
31
|
if(null===a||a===void 0)return a;// Primitives should be returned as-is (text nodes, numbers, booleans)
|
|
45
32
|
var e=_typeof(a);if("string"===e||"number"===e||"boolean"===e)return a;var f=(null===(c=b.rawProps)||void 0===c?void 0:c.nodetheme)||(null===(d=b.rawProps)||void 0===d?void 0:d.theme)||b.props.nodetheme||b.props.theme;// For BaseNode instances, apply current theme if child has no theme
|
|
46
33
|
if(a instanceof BaseNode||isNodeInstance(a)){var g;return null!==(g=a.rawProps)&&void 0!==g&&g.nodetheme||void 0===f?a.render():new BaseNode(a.element,_objectSpread(_objectSpread({},a.rawProps),{},{nodetheme:f})).render()}// Handle React.Component instances
|
|
@@ -81,7 +68,7 @@ return"string"==typeof this.element&&(hasNoStyleTag(this.element)?w=omit(w,"css"
|
|
|
81
68
|
* @param processed The processed child or array of children to clone.
|
|
82
69
|
* @returns A deep clone of the processed children, safe for use in multiple parents.
|
|
83
70
|
* @private
|
|
84
|
-
*/static _cloneProcessedChildren(a){var b=function cloneOne(a){return a instanceof BaseNode?new BaseNode(a.element,_objectSpread({},a.rawProps)):a;// NodeInstance returns its own instances when render() is called - we avoid calling render here.
|
|
71
|
+
*/static _cloneProcessedChildren(a){var b=function cloneOne(a){return a instanceof BaseNode||isNodeInstance(a)?new BaseNode(a.element,_objectSpread({},a.rawProps)):a;// NodeInstance returns its own instances when render() is called - we avoid calling render here.
|
|
85
72
|
// For other objects/primitives, return as-is (they are immutable or safe to reuse).
|
|
86
73
|
};return Array.isArray(a)?a.map(function(a){return b(a)}):b(a)}/**
|
|
87
74
|
* Retrieves cached processed children for a given set of `children` and an optional `theme`.
|
|
@@ -124,8 +111,8 @@ if(BaseNode._processedChildrenMapCache.has(d))return void BaseNode._processedChi
|
|
|
124
111
|
* @param theme The theme to propagate to the children.
|
|
125
112
|
* @returns The processed children, ready for normalization and rendering.
|
|
126
113
|
* @private
|
|
127
|
-
*/_processChildren(a,b){
|
|
128
|
-
var
|
|
114
|
+
*/_processChildren(a,b){if(a){// Use RSC-safe caching strategy
|
|
115
|
+
var c=this._getCachedChildren(a,b);if(c)return c;var d;return d="function"==typeof a?a:Array.isArray(a)?a.map(function(a){return BaseNode._processRawNode(a,b)}):BaseNode._processRawNode(a,b),BaseNode._isServer||this._setCachedChildren(a,b,d),d}}/**
|
|
129
116
|
* Renders a processed `NodeElement` into a `ReactNode`, applying a theme and key if necessary.
|
|
130
117
|
*
|
|
131
118
|
* This static method centralizes the logic for converting various types of processed elements
|
|
@@ -143,21 +130,25 @@ var d=this._getCachedChildren(a,b);if(d)return d;var e;return e="function"==type
|
|
|
143
130
|
* @private
|
|
144
131
|
* @static
|
|
145
132
|
*/static _renderProcessedNode(a,b,c){var d={};// 1. BaseNode instance: re-wrap to apply key/theme if needed
|
|
146
|
-
if(void 0!==c&&(d.key=c),a instanceof BaseNode){var e,f,g,h,i,j=(null===(e=a.rawProps)||void 0===e?void 0:e.theme)||(null===(f=a.rawProps)||void 0===f?void 0:f.nodetheme)||b,k=null===(g=a.rawProps)||void 0===g?void 0:g.key;return k===c&&j===((null===(h=a.rawProps)||void 0===h?void 0:h.nodetheme)||(null===(i=a.rawProps)||void 0===i?void 0:i.theme))?a.render():new BaseNode(a.element,_objectSpread(_objectSpread(_objectSpread({},a.rawProps),d),{},{nodetheme:j})).render()}// 2. React class component type: wrap in BaseNode
|
|
133
|
+
if(void 0!==c&&(d.key=c),a instanceof BaseNode||isNodeInstance(a)){var e,f,g,h,i,j=(null===(e=a.rawProps)||void 0===e?void 0:e.theme)||(null===(f=a.rawProps)||void 0===f?void 0:f.nodetheme)||b,k=null===(g=a.rawProps)||void 0===g?void 0:g.key;return k===c&&j===((null===(h=a.rawProps)||void 0===h?void 0:h.nodetheme)||(null===(i=a.rawProps)||void 0===i?void 0:i.theme))?a.render():new BaseNode(a.element,_objectSpread(_objectSpread(_objectSpread({},a.rawProps),d),{},{nodetheme:j})).render()}// 2. React class component type: wrap in BaseNode
|
|
147
134
|
return isReactClassComponent(a)?new BaseNode(a,d).render():isNodeInstance(a)?a.render():a instanceof React.Component?a.render():"function"==typeof a?createElement(a,{key:c}):a;// 3. NodeInstance object: call its render
|
|
148
135
|
// 4. React.Component instance: call its render
|
|
149
136
|
// 5. Functional component: create element with key
|
|
150
137
|
// 6. Other valid ReactNode types
|
|
151
138
|
}/**
|
|
152
|
-
*
|
|
153
|
-
* @param
|
|
139
|
+
* Renders this node into a `ReactNode`, handling function node element.
|
|
140
|
+
* @param node The node to render.
|
|
154
141
|
* @private
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
142
|
+
* @static
|
|
143
|
+
* @example
|
|
144
|
+
* ```typescript
|
|
145
|
+
* const myNode = Node('div', { children: [ () => 'Hello' ] });
|
|
146
|
+
* ```
|
|
147
|
+
*/static _isFunctionChild(a){// Basic function check
|
|
148
|
+
if("function"!=typeof a)return!1;// Exclude React component types
|
|
149
|
+
if(isReactClassComponent(a))return!1;if(isMemo(a))return!1;if(isForwardRef(a))return!1;try{// Try to check if it's a React component instance using prototype
|
|
150
|
+
return!(a.prototype&&"function"==typeof a.prototype.render)}catch(a){// If accessing prototype fails (due to cross-realm), assume it's a function child
|
|
151
|
+
return!0}}/**
|
|
161
152
|
* Renders the output of a function-as-a-child, ensuring theme propagation.
|
|
162
153
|
*
|
|
163
154
|
* This method is designed to handle "render prop" style children (`() => ReactNode`).
|
|
@@ -166,19 +157,18 @@ return!("function"!=typeof a)&&!isReactClassComponent(a)&&!isMemo(a)&&!isForward
|
|
|
166
157
|
* @param props The properties for the function renderer.
|
|
167
158
|
* @param props.render The function to execute to get the child content.
|
|
168
159
|
* @param props.passedTheme The theme to propagate to the rendered child.
|
|
169
|
-
* @param props.processRawNode A reference to the `_processRawNode` method for recursive processing.
|
|
160
|
+
* // * @param props.processRawNode A reference to the `_processRawNode` method for recursive processing.
|
|
170
161
|
* @returns The rendered `ReactNode`.
|
|
171
162
|
* @private
|
|
172
|
-
*/_functionRenderer(a){var b,c=a.render,d=a.passedTheme
|
|
163
|
+
*/static _functionRenderer(a){var b,c=a.render,d=a.passedTheme;// Invoke the render function to get the child node.
|
|
173
164
|
try{b=c()}catch(a){b=null}// Handle null/undefined
|
|
174
165
|
if(null===b||b===void 0)return b;// Handle arrays of elements (common in render props)
|
|
175
|
-
if(Array.isArray(b))return b.map(function(a,b){var c=
|
|
176
|
-
if(b instanceof React.Component){var
|
|
177
|
-
if(b instanceof BaseNode||isNodeInstance(b)){var h
|
|
178
|
-
return void 0===(null===(h
|
|
179
|
-
if("string"==typeof b||"number"==typeof b||"boolean"==typeof b
|
|
180
|
-
)return b
|
|
181
|
-
var j=e?e(b,d):b;return j?BaseNode._renderProcessedNode(j,d):b}/**
|
|
166
|
+
if(Array.isArray(b))return b.map(function(a,b){var c=BaseNode._processRawNode(a,d);return BaseNode._renderProcessedNode(c,d,"".concat(getElementTypeName(a),"-").concat(b))});// Handle React.Component instance
|
|
167
|
+
if(b instanceof React.Component){var e=b.render(),f=BaseNode._processRawNode(e,d);return BaseNode._renderProcessedNode(f,d)}// Handle BaseNode instance or NodeInstance
|
|
168
|
+
if(b instanceof BaseNode||isNodeInstance(b)){var g,h=b;// If nodetheme is missing and passedTheme exists, inject it
|
|
169
|
+
return void 0===(null===(g=h.rawProps)||void 0===g?void 0:g.nodetheme)&&void 0!==d?new BaseNode(h.element,_objectSpread(_objectSpread({},h.rawProps),{},{nodetheme:d})).render():h.render()}// Handle primitives and valid React nodes (string, number, boolean)
|
|
170
|
+
if("string"==typeof b||"number"==typeof b||"boolean"==typeof b)return b;// Process any other result types
|
|
171
|
+
var i=BaseNode._processRawNode(b,d);return i?BaseNode._renderProcessedNode(i,d):b}/**
|
|
182
172
|
* Processes a single raw node, recursively converting it into a `BaseNode` or other renderable type.
|
|
183
173
|
*
|
|
184
174
|
* This is a central method for normalizing children. It handles various types of input:
|
|
@@ -188,33 +178,27 @@ var j=e?e(b,d):b;return j?BaseNode._renderProcessedNode(j,d):b}/**
|
|
|
188
178
|
* - **Valid React Elements**: Converts them into `BaseNode` instances, extracting props and propagating the theme.
|
|
189
179
|
* - **React Component Types**: Wraps them in a `BaseNode` with the parent theme.
|
|
190
180
|
* - **React Component Instances**: Renders them and processes the output recursively.
|
|
191
|
-
*
|
|
192
|
-
*
|
|
193
|
-
* @param rawNode The raw child node to process.
|
|
194
|
-
* @param parentTheme The theme inherited from the parent.
|
|
195
|
-
* @param nodeIndex The index of the child if it is in an array, used for key generation.
|
|
181
|
+
* @param node The raw child node to process.
|
|
182
|
+
* @param passedTheme The theme inherited from the parent.
|
|
196
183
|
* @returns A processed `NodeElement` (typically a `BaseNode` instance or a primitive).
|
|
197
184
|
* @private
|
|
198
|
-
|
|
199
|
-
){var
|
|
185
|
+
* @static
|
|
186
|
+
*/static _processRawNode(a,b){var c=getComponentType(a);// Determine the type of the raw node
|
|
200
187
|
// Case 1: Child is already a BaseNode instance
|
|
201
|
-
if(a instanceof BaseNode){var
|
|
188
|
+
if(a instanceof BaseNode||isNodeInstance(a)){var d=a.rawProps||{},e=d.theme||d.nodetheme||b;// Get initial raw props of the child
|
|
202
189
|
// Prefer child's own theme
|
|
203
190
|
// Check if we can reuse the existing node
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
key:h}));// Create a new BaseNode with merged props and theme
|
|
191
|
+
return d.nodetheme===e&&void 0!==d.key?a:new BaseNode(a.element,_objectSpread(_objectSpread({},d),{},{nodetheme:e// Use the determined theme for the new node
|
|
192
|
+
}));// Create a new BaseNode with merged props and theme
|
|
207
193
|
}// Case 2: Child is a primitive (string, number, boolean, null, undefined)
|
|
208
|
-
if("string"===
|
|
209
|
-
if(
|
|
210
|
-
if(isValidElement(a)){var
|
|
211
|
-
if(isReactClassComponent(a)||"object"===
|
|
212
|
-
return new BaseNode(a,{nodetheme:b
|
|
213
|
-
|
|
214
|
-
if(a instanceof React.Component){var
|
|
215
|
-
return
|
|
216
|
-
// These are returned as-is. If they are elements within an array, React expects them to have keys.
|
|
217
|
-
// This logic primarily adds keys to BaseNode instances we create, other ReactNodes are returned as-is.
|
|
194
|
+
if("string"===c||"number"===c||"boolean"===c||null===a||void 0===a)return a;// Case 3: Child is a function that needs to be called during render (FunctionRenderer).
|
|
195
|
+
if(BaseNode._isFunctionChild(a))return new BaseNode(BaseNode._functionRenderer,{render:a,passedTheme:b});// Case 4: Child is a React Element (JSX element like <div> or <MyComponent>)
|
|
196
|
+
if(isValidElement(a)){var f=a.props,g=f.style,h=_objectWithoutProperties(f,_excluded4),i=_objectSpread(_objectSpread({},h),g||{}),j=i.theme||i.nodetheme||b;return new BaseNode(a.type,_objectSpread(_objectSpread({},i),{},{nodetheme:j}))}// Case 5: Child is an ElementType (string tag, class component, Memo/ForwardRef)
|
|
197
|
+
if(isReactClassComponent(a)||"object"===c&&(isMemo(a)||isForwardRef(a)))// ElementTypes don't have an intrinsic key from the node itself.
|
|
198
|
+
return new BaseNode(a,{nodetheme:b// Apply parent theme
|
|
199
|
+
});// Case 6: Handle instances of React.Component
|
|
200
|
+
if(a instanceof React.Component){var k=a.render();// Recursively process the rendered element with a parent theme and index if available
|
|
201
|
+
return BaseNode._processRawNode(k,b)}// Case 7: Fallback for other ReactNode types (e.g., Fragments, Portals if not caught by isValidElement)
|
|
218
202
|
return a}/**
|
|
219
203
|
* Renders the `BaseNode` into a `ReactElement`.
|
|
220
204
|
*
|
|
@@ -223,22 +207,22 @@ return a}/**
|
|
|
223
207
|
* 1. Validating that the node's `element` type is renderable.
|
|
224
208
|
* 2. Normalizing processed children into `ReactNode`s using `_normalizeChild`.
|
|
225
209
|
* 3. Caching normalized children to avoid re-processing on subsequent renders.
|
|
226
|
-
* 4. Assembling the final props, including `
|
|
210
|
+
* 4. Assembling the final props, including `style`, and other attributes.
|
|
227
211
|
* 5. If the element has a `css` prop, it may be wrapped in a `StyledRenderer` to handle
|
|
228
212
|
* CSS-in-JS styling.
|
|
229
213
|
* 6. Finally, calling `React.createElement` with the element, props, and children.
|
|
230
214
|
* @returns The rendered `ReactElement`.
|
|
231
215
|
* @throws {Error} If the node's `element` is not a valid React element type.
|
|
232
216
|
*/render(){var a=this;if(!isValidElementType(this.element)){var b=getComponentType(this.element);throw new Error("Invalid element type: ".concat(b," provided!"))}// Extract children and key
|
|
233
|
-
var c=this.props,d=c.children,e=c.
|
|
234
|
-
if(this.element===Fragment||isFragment(this.element))return createElement(this.element
|
|
217
|
+
var c=this.props,d=c.children,e=c.css,f=c.nativeProps,g=_objectWithoutProperties(c,_excluded5),h=void 0;if(d!==void 0&&null!==d){if(!this._normalizedChildren||this._childrenHash!==createStableHash(d,this.props.nodetheme||this.props.theme))if(!Array.isArray(d))this._normalizedChildren=this._normalizeChild(d);else if(0<d.length){var i=d.map(function(b){return a._normalizeChild(b)});this._normalizedChildren=i.every(function(a){return null===a||void 0===a})?void 0:i}else this._normalizedChildren=void 0;h=this._normalizedChildren}// If the element is a Fragment, use React.createElement directly
|
|
218
|
+
if(this.element===Fragment||isFragment(this.element))return createElement(this.element,...(Array.isArray(h)?h:[h]));// If the element has a `css` prop and has style tag, render using the `StyledRenderer` component
|
|
235
219
|
// This enables emotion-based style handling for the element
|
|
236
|
-
if(this.element&&!hasNoStyleTag(this.element)&&
|
|
220
|
+
if(this.element&&!hasNoStyleTag(this.element)&&e){// Set displayName for easier debugging in React DevTools
|
|
237
221
|
try{var j=getElementTypeName(this.element);StyledRenderer.displayName="Styled(".concat(j,")")}catch(a){// swallow: displayName is not critical
|
|
238
|
-
}return createElement(StyledRenderer,_objectSpread(_objectSpread({element:this.element},g),{},{
|
|
222
|
+
}return createElement(StyledRenderer,_objectSpread(_objectSpread({element:this.element},g),{},{css:e,suppressHydrationWarning:!0},f),...(Array.isArray(h)?h:[h]))}// For other elements, create the React element directly
|
|
239
223
|
// Set displayName for easier debugging in React DevTools
|
|
240
224
|
try{this.element.displayName=getElementTypeName(this.element)}catch(a){// swallow: displayName is not critical
|
|
241
|
-
}return createElement(this.element,_objectSpread(_objectSpread({},g),
|
|
225
|
+
}return createElement(this.element,_objectSpread(_objectSpread({},g),f),...(Array.isArray(h)?h:[h]))}/**
|
|
242
226
|
* Ensures the necessary DOM elements for portal rendering are created and attached.
|
|
243
227
|
*
|
|
244
228
|
* On the client-side, this method checks for or creates a `div` element appended
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.hoc.d.ts","sourceRoot":"","sources":["../../src/hoc/component.hoc.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,yBAAyB,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAClG,OAAO,EAAE,KAAK,aAAa,EAAE,KAAK,YAAY,EAAkB,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"component.hoc.d.ts","sourceRoot":"","sources":["../../src/hoc/component.hoc.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,yBAAyB,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAClG,OAAO,EAAE,KAAK,aAAa,EAAE,KAAK,YAAY,EAAkB,MAAM,OAAO,CAAA;AAI7E;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,kBAAkB,CAAC,MAAM,IAAI,MAAM,SAAS,SAAS,GAC7D,OAAO,CAAC;IACN,QAAQ,EAAE,QAAQ,CAAA;IAClB,KAAK,EAAE,KAAK,CAAA;CACb,CAAC,GACF,MAAM,GACJ,CAAC,yBAAyB,CAAC,MAAM,CAAC,SAAS,IAAI,GAAG,aAAa,GAAG,MAAM,CAAC,GACzE,OAAO,CAAC;IACN,KAAK,EAAE,OAAO,CAAC,IAAI,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC,CAAA;IACxC,QAAQ,EAAE,QAAQ,CAAA;IAClB,KAAK,EAAE,KAAK,CAAA;CACb,CAAC,CAAA;AAER;;;;;;;;;;;;;GAaG;AACH,wBAAgB,SAAS,CAAC,MAAM,SAAS,SAAS,EAChD,SAAS,EAAE,CAAC,KAAK,EAAE,kBAAkB,CAAC,MAAM,CAAC,KAAK,aAAa,GAC9D,CAAC,KAAK,CAAC,EAAE,kBAAkB,CAAC,MAAM,CAAC,KAAK,YAAY,GAAG,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC,CAAA;AAExF;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,SAAS,CAAC,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAC1D,SAAS,EAAE,CAAC,KAAK,EAAE,kBAAkB,CAAC,MAAM,CAAC,KAAK,aAAa,GAC9D,CAAC,KAAK,EAAE,kBAAkB,CAAC,MAAM,CAAC,KAAK,YAAY,GAAG,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}function _defineProperty(a,b,c){return(b=_toPropertyKey(b))in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"==_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!=_typeof(a)||!a)return a;var c=a[Symbol.toPrimitive];if(void 0!==c){var d=c.call(a,b||"default");if("object"!=_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}import{BaseNode,Node}from"../core.node.js";import{getElementTypeName}from"../helper/common.helper.js";/**
|
|
1
|
+
"use strict";function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}function _defineProperty(a,b,c){return(b=_toPropertyKey(b))in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"==_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!=_typeof(a)||!a)return a;var c=a[Symbol.toPrimitive];if(void 0!==c){var d=c.call(a,b||"default");if("object"!=_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}import{BaseNode,Node}from"../core.node.js";import{getElementTypeName}from"../helper/common.helper.js";import{isNodeInstance}from"../helper/node.helper.js";/**
|
|
2
2
|
* Props definition for components wrapped using the `Component` higher-order function.
|
|
3
3
|
*
|
|
4
4
|
* This type adapts based on whether the underlying component defines its own props:
|
|
@@ -48,4 +48,4 @@
|
|
|
48
48
|
*//**
|
|
49
49
|
* Internal implementation of the `Component` HOC.
|
|
50
50
|
* Handles theme propagation, BaseNode conversion, and wrapper creation.
|
|
51
|
-
*/export function Component(a){function Func(){var a=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return Node(c,a).render()}var b=getElementTypeName(a),c=function Renderer(b){var c=a(b);if(c instanceof BaseNode){var d,e,f=(null===(d=c.rawProps)||void 0===d?void 0:d.nodetheme)||(null===(e=c.rawProps)||void 0===e?void 0:e.theme)||b.nodetheme||b.theme;return Node(c.element,_objectSpread(_objectSpread({},c.rawProps),{},{nodetheme:f})).render()}return c};return c.displayName="Renderer(".concat(b,")"),Func.displayName="Component(".concat(b,")"),Func}
|
|
51
|
+
*/export function Component(a){function Func(){var a=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return Node(c,a).render()}var b=getElementTypeName(a),c=function Renderer(b){var c=a(b);if(c instanceof BaseNode||isNodeInstance(c)){var d,e,f=(null===(d=c.rawProps)||void 0===d?void 0:d.nodetheme)||(null===(e=c.rawProps)||void 0===e?void 0:e.theme)||b.nodetheme||b.theme;return Node(c.element,_objectSpread(_objectSpread({},c.rawProps),{},{nodetheme:f})).render()}return c};return c.displayName="Renderer(".concat(b,")"),Func.displayName="Component(".concat(b,")"),Func}
|
package/dist/node.type.d.ts
CHANGED
|
@@ -20,7 +20,7 @@ export type NonArrayReactNode = Exclude<ReactNode, ReactNode[]>;
|
|
|
20
20
|
* Defines the various types that can represent a "node" in the Meonode system.
|
|
21
21
|
* This includes React elements, components, promises resolving to React nodes, and NodeInstance objects.
|
|
22
22
|
*/
|
|
23
|
-
export type NodeElement = ExoticComponent<any> | NonArrayReactNode | Promise<Awaited<NonArrayReactNode>> | Component<any, any, any> | ElementType | ComponentType<any> | NodeInstance<any> | ((props?: any) =>
|
|
23
|
+
export type NodeElement = ExoticComponent<any> | NonArrayReactNode | Promise<Awaited<NonArrayReactNode>> | Component<any, any, any> | ElementType | ComponentType<any> | NodeInstance<any> | NodeFunction<any> | ((props?: Record<string, any>) => ExoticComponent<any> | NonArrayReactNode | Component<any, any, any> | ElementType | ComponentType<any> | NodeInstance<any>);
|
|
24
24
|
export type NodeElementType = ElementType | ExoticComponent<any>;
|
|
25
25
|
/** A single NodeElement or an array of NodeElements */
|
|
26
26
|
export type Children = NodeElement | NodeElement[];
|
|
@@ -127,6 +127,13 @@ export type NodeProps<E extends NodeElement> = Omit<PropsOf<E>, keyof CSSPropert
|
|
|
127
127
|
export type RawNodeProps<E extends NodeElement> = Partial<NodeProps<E>> & {
|
|
128
128
|
nodetheme?: Theme;
|
|
129
129
|
};
|
|
130
|
+
/**
|
|
131
|
+
* Function type for dynamic node content generation.
|
|
132
|
+
* Accepts optional NodeProps and returns a ReactNode or NodeInstance.
|
|
133
|
+
* Enables advanced patterns like render props and dynamic theming.
|
|
134
|
+
* @template E - The element type these props apply to
|
|
135
|
+
*/
|
|
136
|
+
export type NodeFunction<E extends ReactNode | NodeInstance = ReactNode | NodeInstance> = (props?: NodeProps<E>) => ReactNode | NodeInstance | React.Component;
|
|
130
137
|
/**
|
|
131
138
|
* Props interface for the internal FunctionRenderer component.
|
|
132
139
|
* Handles dynamic function children within React's component lifecycle:
|
|
@@ -134,12 +141,11 @@ export type RawNodeProps<E extends NodeElement> = Partial<NodeProps<E>> & {
|
|
|
134
141
|
* - Maintains theme context for rendered content
|
|
135
142
|
* - Enables hook usage in function children
|
|
136
143
|
*/
|
|
137
|
-
export interface FunctionRendererProps<E extends
|
|
144
|
+
export interface FunctionRendererProps<E extends ReactNode | NodeInstance> {
|
|
138
145
|
/** Function that returns the child content to render */
|
|
139
|
-
render:
|
|
146
|
+
render: NodeFunction<E>;
|
|
140
147
|
/** Theme context to be applied to the rendered content */
|
|
141
148
|
passedTheme?: Theme;
|
|
142
|
-
processRawNode: (node: NodeElement, parentTheme?: Theme, childIndex?: number) => NodeElement;
|
|
143
149
|
}
|
|
144
150
|
export type ComponentNode = (NodeInstance<any> | ReactNode) | (() => NodeInstance<any> | ReactNode);
|
|
145
151
|
/**
|
package/dist/node.type.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node.type.d.ts","sourceRoot":"","sources":["../src/node.type.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EACZ,KAAK,aAAa,EAClB,KAAK,SAAS,EACd,KAAK,GAAG,EACR,KAAK,WAAW,EAChB,KAAK,aAAa,EAClB,KAAK,qBAAqB,EAC1B,KAAK,SAAS,EACd,KAAK,eAAe,EACpB,KAAK,YAAY,EAClB,MAAM,OAAO,CAAA;AACd,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAA;AAEnE,wBAAwB;AACxB,0DAA0D;AAC1D,KAAK,YAAY,CAAC,CAAC,IAAI;KACpB,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,MAAM,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,KAAK,GAAG,CAAC;CACxD,CAAC,MAAM,CAAC,CAAC,CAAA;AAEV,4DAA4D;AAC5D,MAAM,MAAM,gBAAgB,CAAC,CAAC,IAAI,YAAY,CAAC,CAAC,CAAC,SAAS,KAAK,GAAG,KAAK,GAAG,IAAI,CAAA;AAE9E,4DAA4D;AAC5D,MAAM,WAAW,eAAe;IAC9B,GAAG,CAAC,EAAE,MAAM,CAAA;CACb;AAED;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC,SAAS,EAAE,SAAS,EAAE,CAAC,CAAA;AAE/D;;;GAGG;AACH,MAAM,MAAM,WAAW,GACnB,eAAe,CAAC,GAAG,CAAC,GACpB,iBAAiB,GACjB,OAAO,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAC,GACnC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GACxB,WAAW,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op styling, built-in theming, smart prop handling (including raw property pass-through), and dynamic children.",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.22",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/main.js",
|
|
7
7
|
"types": "./dist/main.d.ts",
|
|
@@ -48,19 +48,19 @@
|
|
|
48
48
|
"@babel/preset-typescript": "^7.27.1",
|
|
49
49
|
"@emotion/cache": "^11.14.0",
|
|
50
50
|
"@emotion/jest": "^11.13.0",
|
|
51
|
-
"@eslint/js": "^9.
|
|
51
|
+
"@eslint/js": "^9.36.0",
|
|
52
52
|
"@testing-library/dom": "^10.4.1",
|
|
53
53
|
"@testing-library/jest-dom": "^6.8.0",
|
|
54
54
|
"@testing-library/react": "^16.3.0",
|
|
55
55
|
"@types/jest": "^30.0.0",
|
|
56
|
-
"@types/react": "^19.1.
|
|
56
|
+
"@types/react": "^19.1.13",
|
|
57
57
|
"@types/react-dom": "^19.1.9",
|
|
58
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
59
|
-
"@typescript-eslint/parser": "^8.
|
|
60
|
-
"@typescript/native-preview": "^7.0.0-dev.
|
|
58
|
+
"@typescript-eslint/eslint-plugin": "^8.44.1",
|
|
59
|
+
"@typescript-eslint/parser": "^8.44.1",
|
|
60
|
+
"@typescript/native-preview": "^7.0.0-dev.20250922.1",
|
|
61
61
|
"babel-plugin-module-resolver": "^5.0.2",
|
|
62
62
|
"babel-preset-minify": "0.5.2",
|
|
63
|
-
"eslint": "^9.
|
|
63
|
+
"eslint": "^9.36.0",
|
|
64
64
|
"eslint-plugin-jsdoc": "^55.4.0",
|
|
65
65
|
"eslint-plugin-prettier": "^5.5.4",
|
|
66
66
|
"eslint-plugin-unused-imports": "^4.2.0",
|
|
@@ -71,10 +71,10 @@
|
|
|
71
71
|
"prettier": "^3.6.2",
|
|
72
72
|
"react": "^19.1.1",
|
|
73
73
|
"react-dom": "^19.1.1",
|
|
74
|
-
"ts-jest": "^29.4.
|
|
74
|
+
"ts-jest": "^29.4.4",
|
|
75
75
|
"tsc-alias": "^1.8.16",
|
|
76
76
|
"typescript": "^5.9.2",
|
|
77
|
-
"typescript-eslint": "^8.
|
|
77
|
+
"typescript-eslint": "^8.44.1"
|
|
78
78
|
},
|
|
79
79
|
"packageManager": "yarn@4.10.2",
|
|
80
80
|
"peerDependencies": {
|