@lukso/transaction-view-core 0.6.9 → 0.6.10-dev.2df3eae
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/.turbo/turbo-build.log +18 -18
- package/.turbo/turbo-typecheck.log +1 -1
- package/CHANGELOG.md +9 -0
- package/dist/index.cjs +10 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +9 -5
- package/dist/index.js.map +1 -1
- package/dist/shared/index.cjs +2 -0
- package/dist/shared/index.cjs.map +1 -1
- package/dist/shared/index.d.cts +29 -1
- package/dist/shared/index.d.ts +29 -1
- package/dist/shared/index.js +1 -0
- package/dist/shared/index.js.map +1 -1
- package/package.json +3 -3
- package/src/components/asset-card.ts +8 -5
- package/src/shared/address-view.ts +1 -1
- package/src/shared/index.ts +1 -0
- package/src/shared/safe-custom-element.ts +1 -0
package/dist/shared/index.d.cts
CHANGED
|
@@ -559,6 +559,34 @@ declare global {
|
|
|
559
559
|
}
|
|
560
560
|
}
|
|
561
561
|
|
|
562
|
+
/**
|
|
563
|
+
* SSR-safe custom element decorator that prevents duplicate registration errors.
|
|
564
|
+
*
|
|
565
|
+
* ## Why this exists
|
|
566
|
+
*
|
|
567
|
+
* The standard `@customElement()` decorator from Lit will throw an error if
|
|
568
|
+
* a component is registered twice. This can happen in SSR environments where:
|
|
569
|
+
* - Components are dynamically imported via multiple paths
|
|
570
|
+
* - HMR causes modules to be re-executed during development
|
|
571
|
+
* - Server and client bundles both try to register components
|
|
572
|
+
*
|
|
573
|
+
* ## Usage
|
|
574
|
+
*
|
|
575
|
+
* Use this instead of `@customElement()`:
|
|
576
|
+
* ```ts
|
|
577
|
+
* import { safeCustomElement } from './safe-custom-element'
|
|
578
|
+
*
|
|
579
|
+
* @safeCustomElement('my-component')
|
|
580
|
+
* export class MyComponent extends LitElement {
|
|
581
|
+
* // ...
|
|
582
|
+
* }
|
|
583
|
+
* ```
|
|
584
|
+
*
|
|
585
|
+
* @param tagName - The custom element tag name (must contain a hyphen)
|
|
586
|
+
* @returns A class decorator that safely registers the element
|
|
587
|
+
*/
|
|
588
|
+
declare function safeCustomElement(tagName: string): <T extends CustomElementConstructor>(classOrDescriptor: T) => T;
|
|
589
|
+
|
|
562
590
|
/**
|
|
563
591
|
* ScrollToBottomButton (core) - reusable scroll helper.
|
|
564
592
|
* Emits `scroll-to-bottom` when clicked.
|
|
@@ -872,4 +900,4 @@ declare global {
|
|
|
872
900
|
}
|
|
873
901
|
}
|
|
874
902
|
|
|
875
|
-
export { type AddressData$1 as AddressData, AddressDisplay, AddressView, CustomOption, CustomSelect, FunctionNameView, GasProviderView, IconView, type ImageLoadState, ImageLoaderController, MultiSignalController, NotificationView, type ProgressSegment, ProgressView, ScrollToBottomButton, type SelectOption, SignalController, TransactionSignalController, TransactionViewController, type TransactionViewState, UrlView, ValueView, useImageLoader, useSignal, useSignals, useTransactionSignal, useTransactionView };
|
|
903
|
+
export { type AddressData$1 as AddressData, AddressDisplay, AddressView, CustomOption, CustomSelect, FunctionNameView, GasProviderView, IconView, type ImageLoadState, ImageLoaderController, MultiSignalController, NotificationView, type ProgressSegment, ProgressView, ScrollToBottomButton, type SelectOption, SignalController, TransactionSignalController, TransactionViewController, type TransactionViewState, UrlView, ValueView, safeCustomElement, useImageLoader, useSignal, useSignals, useTransactionSignal, useTransactionView };
|
package/dist/shared/index.d.ts
CHANGED
|
@@ -559,6 +559,34 @@ declare global {
|
|
|
559
559
|
}
|
|
560
560
|
}
|
|
561
561
|
|
|
562
|
+
/**
|
|
563
|
+
* SSR-safe custom element decorator that prevents duplicate registration errors.
|
|
564
|
+
*
|
|
565
|
+
* ## Why this exists
|
|
566
|
+
*
|
|
567
|
+
* The standard `@customElement()` decorator from Lit will throw an error if
|
|
568
|
+
* a component is registered twice. This can happen in SSR environments where:
|
|
569
|
+
* - Components are dynamically imported via multiple paths
|
|
570
|
+
* - HMR causes modules to be re-executed during development
|
|
571
|
+
* - Server and client bundles both try to register components
|
|
572
|
+
*
|
|
573
|
+
* ## Usage
|
|
574
|
+
*
|
|
575
|
+
* Use this instead of `@customElement()`:
|
|
576
|
+
* ```ts
|
|
577
|
+
* import { safeCustomElement } from './safe-custom-element'
|
|
578
|
+
*
|
|
579
|
+
* @safeCustomElement('my-component')
|
|
580
|
+
* export class MyComponent extends LitElement {
|
|
581
|
+
* // ...
|
|
582
|
+
* }
|
|
583
|
+
* ```
|
|
584
|
+
*
|
|
585
|
+
* @param tagName - The custom element tag name (must contain a hyphen)
|
|
586
|
+
* @returns A class decorator that safely registers the element
|
|
587
|
+
*/
|
|
588
|
+
declare function safeCustomElement(tagName: string): <T extends CustomElementConstructor>(classOrDescriptor: T) => T;
|
|
589
|
+
|
|
562
590
|
/**
|
|
563
591
|
* ScrollToBottomButton (core) - reusable scroll helper.
|
|
564
592
|
* Emits `scroll-to-bottom` when clicked.
|
|
@@ -872,4 +900,4 @@ declare global {
|
|
|
872
900
|
}
|
|
873
901
|
}
|
|
874
902
|
|
|
875
|
-
export { type AddressData$1 as AddressData, AddressDisplay, AddressView, CustomOption, CustomSelect, FunctionNameView, GasProviderView, IconView, type ImageLoadState, ImageLoaderController, MultiSignalController, NotificationView, type ProgressSegment, ProgressView, ScrollToBottomButton, type SelectOption, SignalController, TransactionSignalController, TransactionViewController, type TransactionViewState, UrlView, ValueView, useImageLoader, useSignal, useSignals, useTransactionSignal, useTransactionView };
|
|
903
|
+
export { type AddressData$1 as AddressData, AddressDisplay, AddressView, CustomOption, CustomSelect, FunctionNameView, GasProviderView, IconView, type ImageLoadState, ImageLoaderController, MultiSignalController, NotificationView, type ProgressSegment, ProgressView, ScrollToBottomButton, type SelectOption, SignalController, TransactionSignalController, TransactionViewController, type TransactionViewState, UrlView, ValueView, safeCustomElement, useImageLoader, useSignal, useSignals, useTransactionSignal, useTransactionView };
|