arkada-widgets 1.0.3 → 1.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.
Files changed (53) hide show
  1. package/README.md +38 -37
  2. package/dist/.gitkeep +0 -0
  3. package/dist/arkada-widgets.css +2 -0
  4. package/dist/arkada-widgets.js +2 -0
  5. package/dist/arkada-wvbs-widget-DLewRKfj.js +9502 -0
  6. package/dist/arkada-wvbs-widget.js +2 -0
  7. package/dist/index.cjs +1797 -0
  8. package/dist/index.cjs.map +1 -0
  9. package/dist/index.css +123 -0
  10. package/dist/index.css.map +1 -0
  11. package/dist/index.d.cts +53 -0
  12. package/dist/index.d.ts +53 -0
  13. package/dist/index.js +1769 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/shared/api/client.d.ts +2 -0
  16. package/dist/shared/api/types.d.ts +165 -0
  17. package/dist/shared/config/index.d.ts +5 -0
  18. package/dist/shared/hooks/useTheme.d.ts +2 -0
  19. package/dist/shared/utils/cloudflare.d.ts +1 -0
  20. package/dist/shared/utils/cn.d.ts +2 -0
  21. package/dist/ui-kit/components/base/Button.d.ts +6 -0
  22. package/dist/ui-kit/components/base/NetworkIcon.d.ts +7 -0
  23. package/dist/ui-kit/components/base/StatusIcon.d.ts +8 -0
  24. package/dist/ui-kit/components/base/TabGroup.d.ts +11 -0
  25. package/dist/ui-kit/components/base/index.d.ts +4 -0
  26. package/dist/ui-kit/tokens/colors.d.ts +44 -0
  27. package/dist/ui-kit/tokens/index.d.ts +3 -0
  28. package/dist/ui-kit/tokens/spacing.d.ts +20 -0
  29. package/dist/ui-kit/tokens/typography.d.ts +19 -0
  30. package/dist/web-components/arkada-wv-widget.d.ts +371 -0
  31. package/dist/web-components/arkada-wvbs-widget.d.ts +379 -0
  32. package/dist/web-components/base/createArkadaElement.d.ts +404 -0
  33. package/dist/web-components/index.d.ts +18 -0
  34. package/dist/widgets/verify-wallet-button/components/VerifyWalletButton.d.ts +15 -0
  35. package/dist/widgets/verify-wallet-button/components/__stories__/VerifyWalletButton.stories.d.ts +37 -0
  36. package/dist/widgets/verify-wallet-button/components/icons.d.ts +35 -0
  37. package/dist/widgets/verify-wallet-button/index.d.ts +3 -0
  38. package/dist/widgets/verify-wallet-button/model/types.d.ts +32 -0
  39. package/dist/widgets/wallet-verification/components/ChainListEntry.d.ts +9 -0
  40. package/dist/widgets/wallet-verification/components/ProgressBar.d.ts +6 -0
  41. package/dist/widgets/wallet-verification/components/RankDisplay.d.ts +8 -0
  42. package/dist/widgets/wallet-verification/components/WalletScores.d.ts +7 -0
  43. package/dist/widgets/wallet-verification/components/WalletVerificationWidget.d.ts +11 -0
  44. package/dist/widgets/wallet-verification/components/WidgetChainsList.d.ts +9 -0
  45. package/dist/widgets/wallet-verification/components/WidgetHeader.d.ts +8 -0
  46. package/dist/widgets/wallet-verification/index.d.ts +3 -0
  47. package/dist/widgets/wallet-verification/model/badge-config.d.ts +3 -0
  48. package/dist/widgets/wallet-verification/model/types.d.ts +42 -0
  49. package/dist/widgets/wallet-verification-button/components/WalletVerificationButton.d.ts +16 -0
  50. package/dist/widgets/wallet-verification-button/components/__stories__/WalletVerificationButton.stories.d.ts +43 -0
  51. package/dist/widgets/wallet-verification-button/hooks/useWalletVerification.d.ts +16 -0
  52. package/dist/widgets/wallet-verification-button/index.d.ts +2 -0
  53. package/package.json +1 -1
@@ -0,0 +1,42 @@
1
+ export declare const WalletBadges: {
2
+ readonly UNVERIFIED: 0;
3
+ readonly IDENTIFIED: 1;
4
+ readonly BASIC: 2;
5
+ readonly VERIFIED: 3;
6
+ readonly TRUSTED: 4;
7
+ readonly ELITE: 5;
8
+ readonly LEGENDARY: 6;
9
+ };
10
+ export type WalletBadges = (typeof WalletBadges)[keyof typeof WalletBadges];
11
+ export interface BadgeConfig {
12
+ label: string;
13
+ gradient: string;
14
+ textGradient: string;
15
+ textGradientEntry: string;
16
+ glowColor: string;
17
+ icon: string;
18
+ outlineGradient: string;
19
+ mainGradient: string;
20
+ }
21
+ export interface WalletEntry {
22
+ id: string;
23
+ network: {
24
+ name: string;
25
+ icon: string;
26
+ };
27
+ status: WalletBadges;
28
+ isOutdated?: boolean;
29
+ statusLabel: string;
30
+ }
31
+ export interface WalletVerificationData {
32
+ title: string;
33
+ subtitle: string;
34
+ currentBadge: WalletBadges;
35
+ nextBadge: WalletBadges;
36
+ verifiedCount: number;
37
+ totalCount: number;
38
+ outdatedCount: number;
39
+ progress: number;
40
+ entries: WalletEntry[];
41
+ }
42
+ export type FilterTab = "all" | "verified" | "not-verified";
@@ -0,0 +1,16 @@
1
+ import type { WidgetTheme } from "@/shared/config";
2
+ import { type VerifyWalletVariant } from "@/widgets/verify-wallet-button";
3
+ export interface WalletVerificationButtonProps {
4
+ walletAddress: string;
5
+ referralCode?: string;
6
+ someVerified?: boolean;
7
+ theme?: WidgetTheme;
8
+ variant?: VerifyWalletVariant;
9
+ }
10
+ /**
11
+ * Smart wallet verification button.
12
+ *
13
+ * Fetches verification status for the given address on mount,
14
+ * then delegates all visual rendering to VerifyWalletButton.
15
+ */
16
+ export declare function WalletVerificationButton({ walletAddress, referralCode, someVerified, theme, variant, }: WalletVerificationButtonProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,43 @@
1
+ import type { Meta, StoryObj } from "@storybook/react-vite";
2
+ import { WalletVerificationButton } from "../WalletVerificationButton";
3
+ declare const meta: Meta<typeof WalletVerificationButton>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof WalletVerificationButton>;
6
+ /** Smart button that fetches real verification status for the wallet address. */
7
+ export declare const ReactCompactDark: Story;
8
+ /** Banner layout on a light background. */
9
+ export declare const ReactBannerLight: Story;
10
+ /**
11
+ * The same smart button rendered as a native Web Component (`<arkada-wvbs-widget>`).
12
+ * Styles live in an isolated Shadow DOM — no leakage to or from the host page.
13
+ */
14
+ export declare const WebComponentCompactDark: Story;
15
+ /**
16
+ * Web Component with `pill-wide` variant, light theme, and a referral code.
17
+ * The `ref` query parameter is appended to the verification URL automatically.
18
+ */
19
+ export declare const WebComponentPillWideLight: Story;
20
+ /**
21
+ * Custom brand gradient: orange → violet.
22
+ * Override --wvb-gradient-start / --wvb-gradient-end on the host element.
23
+ */
24
+ export declare const WebComponentCustomGradient: Story;
25
+ /**
26
+ * Custom brand theme: --arkada-bg, --arkada-border, gradient overridden.
27
+ * Shows full control over both shared and widget-specific variables.
28
+ */
29
+ export declare const WebComponentCustomTheme: Story;
30
+ /**
31
+ * Fully customized Web Component example.
32
+ * Demonstrates overriding both shared and button-specific variables together.
33
+ */
34
+ export declare const WebComponentFullyCustomized: Story;
35
+ /**
36
+ * React component with inline CSS variables — same customization API works
37
+ * in plain React context via the wrapping element's style prop.
38
+ */
39
+ export declare const ReactCustomGradient: Story;
40
+ /**
41
+ * Fully customized React example with an extended token set.
42
+ */
43
+ export declare const ReactFullyCustomized: Story;
@@ -0,0 +1,16 @@
1
+ interface WalletVerificationState {
2
+ isVerified: boolean;
3
+ isLoading: boolean;
4
+ error: Error | null;
5
+ }
6
+ /**
7
+ * Fetches wallet verification status once on mount (re-fetches if address changes).
8
+ *
9
+ * someVerified === true:
10
+ * some network in response has rank > 0
11
+ *
12
+ * someVerified === false:
13
+ * global.rank > 0
14
+ */
15
+ export declare function useWalletVerification(walletAddress: string, someVerified?: boolean): WalletVerificationState;
16
+ export {};
@@ -0,0 +1,2 @@
1
+ export { WalletVerificationButton } from "./components/WalletVerificationButton";
2
+ export type { WalletVerificationButtonProps } from "./components/WalletVerificationButton";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "arkada-widgets",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "type": "module",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.js",