@unisphere/nx 3.14.0 → 3.16.0

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 (112) hide show
  1. package/dist/generators/add-documentation/USAGE.md +64 -0
  2. package/dist/generators/add-documentation/add-documentation.d.ts +1 -1
  3. package/dist/generators/add-documentation/add-documentation.d.ts.map +1 -1
  4. package/dist/generators/add-documentation/add-documentation.js +80 -41
  5. package/dist/generators/add-documentation/schema.d.ts +4 -1
  6. package/dist/generators/add-documentation/schema.json +19 -10
  7. package/dist/generators/add-documentation/templates/babel.config.js +3 -0
  8. package/dist/generators/add-documentation/templates/docs/api/overview.md +8 -0
  9. package/dist/generators/add-documentation/templates/docs/changelog/overview.md +8 -0
  10. package/dist/generators/add-documentation/templates/docs/getting-started/overview.md +8 -0
  11. package/dist/generators/add-documentation/templates/docusaurus.config.ts.template +116 -0
  12. package/dist/generators/add-documentation/templates/package.json.template +57 -0
  13. package/dist/generators/add-documentation/templates/postcss.config.js +6 -0
  14. package/dist/generators/add-documentation/templates/sidebars.ts +9 -0
  15. package/dist/generators/add-documentation/templates/src/components/demo-placeholder-card.tsx +33 -0
  16. package/dist/generators/add-documentation/templates/src/components/guides/experiences/genie/integrate-genie-guide.tsx +149 -0
  17. package/dist/generators/add-documentation/templates/src/components/guides/experiences/notifications/notifications-react-guide.tsx +211 -0
  18. package/dist/generators/add-documentation/templates/src/components/homepage-features/index.tsx +239 -0
  19. package/dist/generators/add-documentation/templates/src/components/homepage-features/styles.module.css +87 -0
  20. package/dist/generators/add-documentation/templates/src/components/homepage-modules/index.tsx +76 -0
  21. package/dist/generators/add-documentation/templates/src/components/homepage-modules/styles.module.css +120 -0
  22. package/dist/generators/add-documentation/templates/src/components/homepage-start-now/index.tsx +22 -0
  23. package/dist/generators/add-documentation/templates/src/components/homepage-start-now/styles.module.css +38 -0
  24. package/dist/generators/add-documentation/templates/src/components/interactive-code-panel.tsx +258 -0
  25. package/dist/generators/add-documentation/templates/src/components/introductions/developer-toolbox-experience.tsx +84 -0
  26. package/dist/generators/add-documentation/templates/src/components/introductions/hello-world-experience.tsx +130 -0
  27. package/dist/generators/add-documentation/templates/src/components/introductions/notificaitons-experience.tsx +635 -0
  28. package/dist/generators/add-documentation/templates/src/components/introductions/reactions-experience.tsx +117 -0
  29. package/dist/generators/add-documentation/templates/src/components/ui-shared/introduction-card.tsx +117 -0
  30. package/dist/generators/add-documentation/templates/src/components/ui-shared/playground-card.tsx +67 -0
  31. package/dist/generators/add-documentation/templates/src/components/ui-shared/use-color-mode.ts +20 -0
  32. package/dist/generators/add-documentation/templates/src/components/ui-shared/utils.ts +8 -0
  33. package/dist/generators/add-documentation/templates/src/css/custom.css +487 -0
  34. package/dist/generators/add-documentation/templates/src/css/hero.module.css +190 -0
  35. package/dist/generators/add-documentation/templates/src/pages/index.module.css +59 -0
  36. package/dist/generators/add-documentation/templates/src/pages/index.tsx.template +191 -0
  37. package/dist/generators/add-documentation/templates/src/theme/Navbar/Content/index.tsx +145 -0
  38. package/dist/generators/add-documentation/templates/src/theme/Navbar/Content/styles.module.css +132 -0
  39. package/dist/generators/add-documentation/templates/src/theme/Navbar/MobileSidebar/Header/index.tsx +45 -0
  40. package/dist/generators/add-documentation/templates/static/.nojekyll +0 -0
  41. package/dist/generators/add-documentation/templates/static/docs/overview/unisphere-for-dummies-1.png +0 -0
  42. package/dist/generators/add-documentation/templates/static/docs/overview/unisphere-for-dummies-2.png +0 -0
  43. package/dist/generators/add-documentation/templates/static/docs/overview/unisphere-for-dummies-3.png +0 -0
  44. package/dist/generators/add-documentation/templates/static/docs/overview/unisphere-for-dummies-4.png +0 -0
  45. package/dist/generators/add-documentation/templates/static/homepage/divider.svg +5 -0
  46. package/dist/generators/add-documentation/templates/static/homepage/icons/Architecture.svg +4 -0
  47. package/dist/generators/add-documentation/templates/static/homepage/icons/Cost.svg +4 -0
  48. package/dist/generators/add-documentation/templates/static/homepage/icons/ExternalLink.svg +3 -0
  49. package/dist/generators/add-documentation/templates/static/homepage/icons/Infra.svg +8 -0
  50. package/dist/generators/add-documentation/templates/static/homepage/icons/Redundancies.svg +6 -0
  51. package/dist/generators/add-documentation/templates/static/homepage/icons/Speed.svg +6 -0
  52. package/dist/generators/add-documentation/templates/static/homepage/icons/Standards.svg +4 -0
  53. package/dist/generators/add-documentation/templates/static/homepage/icons/Unified.svg +12 -0
  54. package/dist/generators/add-documentation/templates/static/homepage/services/custo.jpg +0 -0
  55. package/dist/generators/add-documentation/templates/static/homepage/services/flame.jpg +0 -0
  56. package/dist/generators/add-documentation/templates/static/homepage/services/keepr.jpg +0 -0
  57. package/dist/generators/add-documentation/templates/static/homepage/services/loggi.jpg +0 -0
  58. package/dist/generators/add-documentation/templates/static/homepage/services/palleto.jpg +0 -0
  59. package/dist/generators/add-documentation/templates/static/homepage/services/publi.jpg +0 -0
  60. package/dist/generators/add-documentation/templates/static/homepage/services/tinker.jpg +0 -0
  61. package/dist/generators/add-documentation/templates/static/img/favicon.ico +0 -0
  62. package/dist/generators/add-documentation/templates/static/img/logo.svg +6 -0
  63. package/dist/generators/add-documentation/templates/static/img/logo_big.svg +12 -0
  64. package/dist/generators/add-documentation/templates/static/img/logo_big_dark.svg +12 -0
  65. package/dist/generators/add-documentation/templates/static/img/logo_dark.svg +6 -0
  66. package/dist/generators/add-documentation/templates/static/img/unisphere-social-card.jpg +0 -0
  67. package/dist/generators/add-documentation/templates/static/llm/INTEGRATE.md +497 -0
  68. package/dist/generators/add-documentation/templates/static/robots.txt +5 -0
  69. package/dist/generators/add-documentation/templates/static/team/amirc.jpeg +0 -0
  70. package/dist/generators/add-documentation/templates/static/team/erans.jpeg +0 -0
  71. package/dist/generators/add-documentation/templates/static/team/hadass.jpeg +0 -0
  72. package/dist/generators/add-documentation/templates/static/team/hillelc.jpeg +0 -0
  73. package/dist/generators/add-documentation/templates/static/team/idoz.jpeg +0 -0
  74. package/dist/generators/add-documentation/templates/static/team/lianb.jpeg +0 -0
  75. package/dist/generators/add-documentation/templates/static/team/nirb.jpeg +0 -0
  76. package/dist/generators/add-documentation/templates/static/team/nivs.jpeg +0 -0
  77. package/dist/generators/add-documentation/templates/static/team/omric.jpeg +0 -0
  78. package/dist/generators/add-documentation/templates/static/team/roeed.jpeg +0 -0
  79. package/dist/generators/add-documentation/templates/static/team/sivana.jpeg +0 -0
  80. package/dist/generators/add-documentation/templates/static/team/stask.png +0 -0
  81. package/dist/generators/add-documentation/templates/static/team/tanyal.jpeg +0 -0
  82. package/dist/generators/add-documentation/templates/static/team/tomere.jpeg +0 -0
  83. package/dist/generators/add-documentation/templates/static/team/tornikem.jpeg +0 -0
  84. package/dist/generators/add-documentation/templates/static/team/yairn.jpeg +0 -0
  85. package/dist/generators/add-documentation/templates/tailwind.config.js +30 -0
  86. package/dist/generators/add-documentation/templates/tsconfig.json +7 -0
  87. package/dist/generators/add-package/add-package.d.ts.map +1 -1
  88. package/dist/generators/add-package/add-package.js +9 -4
  89. package/dist/generators/add-package/schema.d.ts +1 -1
  90. package/dist/generators/add-package/schema.json +18 -10
  91. package/dist/generators/rename-package/rename-package.d.ts.map +1 -1
  92. package/dist/generators/rename-package/rename-package.js +12 -0
  93. package/dist/generators/utils.d.ts +1 -1
  94. package/dist/generators/utils.d.ts.map +1 -1
  95. package/dist/generators/utils.js +8 -10
  96. package/dist/migrations/3-15-0/add-experience-documentation.d.ts +10 -0
  97. package/dist/migrations/3-15-0/add-experience-documentation.d.ts.map +1 -0
  98. package/dist/migrations/3-15-0/add-experience-documentation.js +20 -0
  99. package/dist/migrations/3-16-0/remove-rollup-patch.d.ts +10 -0
  100. package/dist/migrations/3-16-0/remove-rollup-patch.d.ts.map +1 -0
  101. package/dist/migrations/3-16-0/remove-rollup-patch.js +32 -0
  102. package/dist/migrations/3-6-3/remove-rollup-patch.d.ts +1 -1
  103. package/dist/migrations/3-6-3/remove-rollup-patch.d.ts.map +1 -1
  104. package/dist/migrations/3-6-3/remove-rollup-patch.js +16 -6
  105. package/dist/migrations/3-7-0/update-gitignore-claude-exclusions.d.ts +9 -0
  106. package/dist/migrations/3-7-0/update-gitignore-claude-exclusions.d.ts.map +1 -0
  107. package/dist/migrations/3-7-0/update-gitignore-claude-exclusions.js +68 -0
  108. package/dist/shared.d.ts +4 -2
  109. package/dist/shared.d.ts.map +1 -1
  110. package/dist/shared.js +3 -1
  111. package/migrations.json +35 -0
  112. package/package.json +1 -1
@@ -0,0 +1,76 @@
1
+ import clsx from 'clsx';
2
+ import Heading from '@theme/Heading';
3
+ import styles from './styles.module.css';
4
+
5
+ const ExternalLink = require('@site/static/homepage/icons/ExternalLink.svg').default;
6
+
7
+ type ModuleItem = {
8
+ title: string;
9
+ previewImage: string;
10
+ documentationUrl: string;
11
+ showcaseUrl: string;
12
+ };
13
+
14
+ const ModulesList: ModuleItem[] = [
15
+ {
16
+ title: 'Reactions Module',
17
+ previewImage: 'https://placehold.co/504x260?text=Reactions+Module',
18
+ documentationUrl: '/docs/overview/experiences/reactions',
19
+ showcaseUrl: '/docs/overview/experiences/reactions#showcase',
20
+ },
21
+ ];
22
+
23
+ function Module({
24
+ title,
25
+ previewImage,
26
+ documentationUrl,
27
+ showcaseUrl,
28
+ }: ModuleItem) {
29
+ return (
30
+ <div className={clsx(styles.module)}>
31
+ <a
32
+ href={showcaseUrl}
33
+ className={clsx(styles.moduleShowcasePreviewContainer)}
34
+ >
35
+ <img
36
+ src={previewImage}
37
+ className={clsx(styles.modulePreviewImage)}
38
+ alt={`${title} module preview image`}
39
+ />
40
+
41
+ <div className={clsx(styles.moduleShowcasePreviewOverlay)}>
42
+ <ExternalLink className={clsx(styles.moduleShowcasePreviewIcon)} />
43
+ </div>
44
+ </a>
45
+ <div>
46
+ <Heading as="h3" className={clsx(styles.moduleTitle)}>
47
+ {title}
48
+ </Heading>
49
+ <div className={clsx(styles.moduleNavigation)}>
50
+ <a href={documentationUrl} className={clsx(styles.moduleLink)}>
51
+ Documentation
52
+ </a>
53
+ <span>•</span>
54
+ <a href={showcaseUrl} className={clsx(styles.moduleLink)}>
55
+ Showcase
56
+ </a>
57
+ </div>
58
+ </div>
59
+ </div>
60
+ );
61
+ }
62
+
63
+ export default function HomepageModules(): JSX.Element {
64
+ return (
65
+ <section className={styles.modules}>
66
+ <Heading as="h2" className={clsx('text--center', styles.heading)}>
67
+ Modules catalog
68
+ </Heading>
69
+ <div className={clsx('container', styles.modulesContainer)}>
70
+ {ModulesList.map((props, idx) => (
71
+ <Module key={idx} {...props} />
72
+ ))}
73
+ </div>
74
+ </section>
75
+ );
76
+ }
@@ -0,0 +1,120 @@
1
+ .modules {
2
+ display: flex;
3
+ align-items: center;
4
+ flex-direction: column;
5
+ gap: 2.5rem;
6
+ padding: 2rem 0;
7
+ width: 100%;
8
+ max-width: 64rem;
9
+ margin: 0 auto;
10
+ margin-bottom: 3rem;
11
+ }
12
+
13
+ .modulesContainer {
14
+ display: grid;
15
+ grid-template-columns: repeat(2, 1fr);
16
+ grid-auto-rows: auto;
17
+ gap: 1rem;
18
+ }
19
+
20
+ @media screen and (max-width: 768px) {
21
+ .modulesContainer {
22
+ grid-template-columns: repeat(1, 1fr);
23
+ }
24
+ }
25
+
26
+ .modulesContainer > :nth-child(2n) {
27
+ grid-column: span 1;
28
+ }
29
+
30
+ .modulesContainer > :nth-child(2n+1):only-child {
31
+ justify-self: center;
32
+ grid-column: span 2;
33
+ }
34
+
35
+ .heading {
36
+ font-size: 3.5rem;
37
+ font-weight: 500;
38
+ font-style: italic;
39
+ line-height: 4.375rem;
40
+ }
41
+
42
+ @media screen and (max-width: 489px) {
43
+ .heading {
44
+ font-size: 2.5rem;
45
+ }
46
+ }
47
+
48
+ @media screen and (max-width: 369px) {
49
+ .heading {
50
+ font-size: 1.5rem;
51
+ }
52
+ }
53
+
54
+ .module {
55
+ max-width: 31.5rem;
56
+ display: flex;
57
+ flex-direction: column;
58
+ gap: 1.25rem;
59
+ justify-self: center;
60
+ }
61
+
62
+ .moduleShowcasePreviewContainer {
63
+ position: relative;
64
+ display: inline-block;
65
+ overflow: hidden;
66
+ text-decoration: none;
67
+ color: inherit;
68
+ }
69
+
70
+ .moduleShowcasePreviewContainer:hover .moduleShowcasePreviewIcon,
71
+ .moduleShowcasePreviewContainer:hover .moduleShowcasePreviewOverlay {
72
+ opacity: 1;
73
+ }
74
+
75
+ .moduleShowcasePreviewOverlay {
76
+ position: absolute;
77
+ top: 0;
78
+ left: 0;
79
+ width: 100%;
80
+ height: 100%;
81
+ background-color: rgba(0, 0, 0, 0.5);
82
+ opacity: 0;
83
+ transition: opacity 0.3s ease;
84
+ display: flex;
85
+ justify-content: center;
86
+ align-items: center;
87
+ border-radius: 0.5rem;
88
+ }
89
+
90
+ .moduleShowcasePreviewIcon {
91
+ position: absolute;
92
+ top: 50%;
93
+ left: 50%;
94
+ transform: translate(-50%, -50%);
95
+ opacity: 0;
96
+ transition: opacity 0.3s ease;
97
+ color: #FFFFFF;
98
+ width: 4rem;
99
+ height: 4rem;
100
+ }
101
+
102
+ .modulePreviewImage {
103
+ border-radius: 0.5rem;
104
+ border: thin solid var(--uc-border-color);
105
+ display: block;
106
+ width: 100%;
107
+ height: auto;
108
+ }
109
+
110
+ .moduleTitle {
111
+ font-size: 1.125rem;
112
+ font-weight: 700;
113
+ line-height: 1.35rem;
114
+ margin: 0;
115
+ }
116
+
117
+ .moduleNavigation {
118
+ display: flex;
119
+ gap: 0.5rem;
120
+ }
@@ -0,0 +1,22 @@
1
+ import clsx from 'clsx';
2
+ import Heading from '@theme/Heading';
3
+ import styles from './styles.module.css';
4
+
5
+ const Divider = require('@site/static/homepage/divider.svg').default;
6
+
7
+ export default function HomepageStartNow(): JSX.Element {
8
+ return (
9
+ <section className={styles.startNow}>
10
+ <Heading as="h2" className={clsx('text--center', styles.heading)}>
11
+ Ready to integrate Unisphere into your application
12
+ </Heading>
13
+ <a
14
+ className={clsx('uc-button', styles.startNowBtn)}
15
+ href="/docs/documentation/overview"
16
+ >
17
+ Start now
18
+ </a>
19
+ <Divider className={clsx(styles.divider)} alt="Divider image"/>
20
+ </section>
21
+ );
22
+ }
@@ -0,0 +1,38 @@
1
+ .startNow {
2
+ display: flex;
3
+ flex-direction: column;
4
+ align-items: center;
5
+ gap: 3rem;
6
+ }
7
+
8
+ .heading {
9
+ font-size: 3.5rem;
10
+ font-weight: 500;
11
+ font-style: italic;
12
+ line-height: 4.375rem;
13
+ max-width: 53.875rem;
14
+ }
15
+
16
+ @media screen and (max-width: 489px) {
17
+ .heading {
18
+ font-size: 2.5rem;
19
+ }
20
+ }
21
+
22
+ @media screen and (max-width: 369px) {
23
+ .heading {
24
+ font-size: 1.5rem;
25
+ }
26
+ }
27
+
28
+ .startNowBtn {
29
+ padding: 1.5rem;
30
+ font-size: 3.5rem;
31
+ line-height: 3rem;
32
+ }
33
+
34
+ .divider {
35
+ height: 6.25rem;
36
+ width: 100%;
37
+ margin: 3rem auto;
38
+ }
@@ -0,0 +1,258 @@
1
+ import React, { useState, MouseEvent } from 'react';
2
+ import CodeBlock from '@theme/CodeBlock';
3
+
4
+ // Simple markdown parser for basic markdown support in descriptions
5
+ const parseMarkdown = (text: string): string => {
6
+ return text
7
+ // Convert [text](url) to <a href="url">text</a>
8
+ .replace(/\[([^\]]+)\]\(([^)]+)\)/g, '<a href="$2" target="_blank" rel="noopener noreferrer">$1</a>')
9
+ // Convert **text** to <strong>text</strong>
10
+ .replace(/\*\*([^*]+)\*\*/g, '<strong>$1</strong>')
11
+ // Convert *text* to <em>text</em>
12
+ .replace(/\*([^*]+)\*/g, '<em>$1</em>')
13
+ // Convert `code` to <code>code</code>
14
+ .replace(/`([^`]+)`/g, '<code>$1</code>')
15
+ // Convert line breaks to <br>
16
+ .replace(/\n/g, '<br>');
17
+ };
18
+
19
+ // Type definitions
20
+ export interface Tab {
21
+ id: string;
22
+ title: string;
23
+ icon: string;
24
+ language?: string;
25
+ content: string;
26
+ description?: string;
27
+ custom?: React.ReactNode;
28
+ }
29
+
30
+ export interface InteractiveCodePanelProps {
31
+ title: string;
32
+ description: string;
33
+ tabs: Tab[];
34
+ defaultTab?: string;
35
+ defaultExpanded?: boolean;
36
+ showCopyButton?: boolean;
37
+ }
38
+
39
+ // Reusable Interactive Code Demo Component
40
+ const InteractiveCodePanel: React.FC<InteractiveCodePanelProps> = ({
41
+ title,
42
+ description,
43
+ tabs,
44
+ defaultTab,
45
+ defaultExpanded = false,
46
+ showCopyButton = true
47
+ }) => {
48
+ const [activeTab, setActiveTab] = useState<string>(defaultTab || tabs[0]?.id || '');
49
+ const [isExpanded, setIsExpanded] = useState<boolean>(defaultExpanded);
50
+ const [copyStatus, setCopyStatus] = useState<string>('');
51
+
52
+ const getCurrentTab = (): Tab => tabs.find(tab => tab.id === activeTab) || tabs[0];
53
+ const currentTab = getCurrentTab();
54
+
55
+ const copyToClipboard = async (text: string): Promise<void> => {
56
+ try {
57
+ await navigator.clipboard.writeText(text);
58
+ setCopyStatus('✅ Copied!');
59
+ setTimeout(() => setCopyStatus(''), 2000);
60
+ } catch (err) {
61
+ setCopyStatus('❌ Failed to copy');
62
+ setTimeout(() => setCopyStatus(''), 2000);
63
+ }
64
+ };
65
+
66
+ const handleMouseEnter = (e: MouseEvent<HTMLButtonElement>, tabId: string): void => {
67
+ if (activeTab !== tabId) {
68
+ (e.target as HTMLButtonElement).style.background = 'var(--ifm-color-emphasis-100)';
69
+ }
70
+ };
71
+
72
+ const handleMouseLeave = (e: MouseEvent<HTMLButtonElement>, tabId: string): void => {
73
+ if (activeTab !== tabId) {
74
+ (e.target as HTMLButtonElement).style.background = 'transparent';
75
+ }
76
+ };
77
+
78
+ const handleCopyButtonMouseEnter = (e: MouseEvent<HTMLButtonElement>): void => {
79
+ (e.target as HTMLButtonElement).style.background = 'var(--ifm-color-primary-dark)';
80
+ };
81
+
82
+ const handleCopyButtonMouseLeave = (e: MouseEvent<HTMLButtonElement>): void => {
83
+ (e.target as HTMLButtonElement).style.background = 'var(--ifm-color-primary)';
84
+ };
85
+
86
+ return (
87
+ <div
88
+ style={{
89
+ background: 'var(--ifm-background-surface-color)',
90
+ border: '1px solid var(--ifm-color-emphasis-300)',
91
+ borderRadius: '12px',
92
+ margin: '24px 0',
93
+ overflow: 'hidden',
94
+ boxShadow: 'var(--ifm-global-shadow-lw)',
95
+ }}
96
+ >
97
+ {/* Header */}
98
+ <div
99
+ style={{
100
+ padding: '20px 24px',
101
+ background: 'var(--ifm-color-primary-contrast-background)',
102
+ borderBottom: '1px solid var(--ifm-color-emphasis-300)',
103
+ display: 'flex',
104
+ alignItems: 'center',
105
+ justifyContent: 'space-between',
106
+ }}
107
+ >
108
+ <div>
109
+ <h3 style={{ margin: '0 0 4px 0', fontSize: '18px', fontWeight: '600', color: 'var(--ifm-heading-color)' }}>
110
+ {title}
111
+ </h3>
112
+ <p style={{ margin: 0, fontSize: '14px', color: 'var(--ifm-color-content-secondary)' }}>
113
+ {description}
114
+ </p>
115
+ </div>
116
+ <button
117
+ onClick={() => setIsExpanded(!isExpanded)}
118
+ style={{
119
+ padding: '8px 16px',
120
+ background: 'var(--ifm-color-primary)',
121
+ color: 'white',
122
+ border: 'none',
123
+ borderRadius: '6px',
124
+ fontSize: '14px',
125
+ fontWeight: '500',
126
+ cursor: 'pointer',
127
+ display: 'flex',
128
+ alignItems: 'center',
129
+ gap: '8px',
130
+ }}
131
+ >
132
+ {isExpanded ? 'Hide Guide' : 'Show Guide'}
133
+ </button>
134
+ </div>
135
+
136
+ {/* Content */}
137
+ {isExpanded && (
138
+ <div style={{ padding: '0' }}>
139
+ {/* Tab Navigation */}
140
+ <div
141
+ style={{
142
+ display: 'flex',
143
+ flexDirection: 'row',
144
+ borderBottom: '1px solid var(--ifm-color-emphasis-300)',
145
+ background: 'var(--ifm-background-color)',
146
+ }}
147
+ className="tab-navigation"
148
+ >
149
+ {tabs.map((tab) => (
150
+ <button
151
+ key={tab.id}
152
+ onClick={() => setActiveTab(tab.id)}
153
+ style={{
154
+ flex: 1,
155
+ padding: '16px 20px',
156
+ background: activeTab === tab.id ? 'var(--ifm-background-surface-color)' : 'transparent',
157
+ border: 'none',
158
+ borderBottom: activeTab === tab.id ? '2px solid var(--ifm-color-primary)' : '2px solid transparent',
159
+ color: activeTab === tab.id ? 'var(--ifm-color-primary)' : 'var(--ifm-color-content-secondary)',
160
+ fontSize: '14px',
161
+ fontWeight: activeTab === tab.id ? '600' : '500',
162
+ cursor: 'pointer',
163
+ display: 'flex',
164
+ alignItems: 'center',
165
+ justifyContent: 'center',
166
+ gap: '8px',
167
+ transition: 'all 0.2s ease',
168
+ }}
169
+ onMouseEnter={(e) => handleMouseEnter(e, tab.id)}
170
+ onMouseLeave={(e) => handleMouseLeave(e, tab.id)}
171
+ >
172
+ <span>{tab.icon}</span>
173
+ {tab.title}
174
+ </button>
175
+ ))}
176
+ </div>
177
+
178
+ {/* Code Content */}
179
+ <div style={{ padding: '24px' }}>
180
+
181
+ {/* Tab Description */}
182
+ {currentTab.description && (
183
+ <div
184
+ style={{
185
+ marginBottom: '16px',
186
+ padding: '16px',
187
+ background: 'var(--ifm-color-info-contrast-background)',
188
+ borderRadius: '8px',
189
+ border: '1px solid var(--ifm-color-info-dark)',
190
+ }}
191
+ >
192
+ <div>
193
+ <h4 style={{ margin: '0 0 8px 0', fontSize: '16px', color: 'var(--ifm-heading-color)' }}>
194
+ {currentTab.icon} {currentTab.title}
195
+ </h4>
196
+ <div
197
+ style={{
198
+ margin: 0,
199
+ fontSize: '14px',
200
+ color: 'var(--ifm-color-content)',
201
+ lineHeight: '1.5'
202
+ }}
203
+ dangerouslySetInnerHTML={{ __html: parseMarkdown(currentTab.description) }}
204
+ />
205
+ </div>
206
+ </div>
207
+ )}
208
+
209
+ <div style={{ position: 'relative' }}>
210
+ {/* Copy Button - only show for code content */}
211
+ {showCopyButton && currentTab.content && !currentTab.custom && (
212
+ <button
213
+ onClick={() => copyToClipboard(currentTab.content)}
214
+ style={{
215
+ position: 'absolute',
216
+ top: '12px',
217
+ right: '12px',
218
+ zIndex: 10,
219
+ padding: '6px 12px',
220
+ background: 'var(--ifm-color-primary)',
221
+ color: 'white',
222
+ border: 'none',
223
+ borderRadius: '4px',
224
+ fontSize: '12px',
225
+ fontWeight: '500',
226
+ cursor: 'pointer',
227
+ display: 'flex',
228
+ alignItems: 'center',
229
+ gap: '4px',
230
+ transition: 'all 0.2s ease',
231
+ }}
232
+ onMouseEnter={handleCopyButtonMouseEnter}
233
+ onMouseLeave={handleCopyButtonMouseLeave}
234
+ >
235
+ 📋 {copyStatus || 'Copy'}
236
+ </button>
237
+ )}
238
+
239
+ {/* Custom Content or Code Block */}
240
+ {currentTab.custom ? (
241
+ <div>{currentTab.custom}</div>
242
+ ) : (
243
+ currentTab.content && <CodeBlock language={currentTab.language || 'text'}>
244
+ {currentTab.content}
245
+ </CodeBlock>
246
+ )}
247
+ </div>
248
+
249
+
250
+ </div>
251
+ </div>
252
+ )}
253
+ </div>
254
+ );
255
+ };
256
+
257
+ // Export both the reusable component and the specific demo
258
+ export { InteractiveCodePanel };
@@ -0,0 +1,84 @@
1
+ import React from 'react';
2
+ import { PlaygroundCard } from '@site/src/components/ui-shared/playground-card';
3
+
4
+ export const DeveloperToolboxExperience: React.FC = () => {
5
+ const toolboxIcon = (
6
+ <svg
7
+ width="32"
8
+ height="32"
9
+ viewBox="0 0 24 24"
10
+ fill="none"
11
+ stroke="currentColor"
12
+ strokeWidth="1.5"
13
+ style={{
14
+ color: 'var(--ifm-color-content-secondary)',
15
+ opacity: 0.7
16
+ }}
17
+ >
18
+ <path d="M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z" />
19
+ </svg>
20
+ );
21
+
22
+ return (
23
+ <PlaygroundCard
24
+ title="Playground — Developer Toolbox"
25
+ icon={toolboxIcon}
26
+ >
27
+ <div style={{ marginBottom: '1rem', color: 'var(--ifm-color-content-secondary)', fontSize: '0.9rem' }}>
28
+ Experience Unisphere's powerful developer tools in real time
29
+ </div>
30
+
31
+ <div
32
+ style={{
33
+ display: 'inline-flex',
34
+ alignItems: 'center',
35
+ gap: '12px',
36
+ padding: '12px 24px',
37
+ backgroundColor: 'var(--ifm-background-surface-color)',
38
+ borderRadius: 'var(--ifm-code-border-radius)',
39
+ border: '1px solid var(--uc-border-color)',
40
+ boxShadow: 'var(--ifm-global-shadow-lw)',
41
+ flexWrap: 'wrap',
42
+ justifyContent: 'center',
43
+ minHeight: '48px',
44
+ }}
45
+ >
46
+ <span style={{ fontSize: '14px', fontWeight: '500', color: 'var(--ifm-color-content)' }}>Press</span>
47
+ <kbd
48
+ style={{
49
+ padding: '4px 8px',
50
+ backgroundColor: 'var(--ifm-background-surface-color)',
51
+ borderRadius: 'var(--ifm-code-border-radius)',
52
+ border: '1px solid var(--uc-border-color)',
53
+ boxShadow: 'var(--ifm-global-shadow-lw)',
54
+ fontSize: '12px',
55
+ fontFamily: 'monospace',
56
+ color: 'var(--ifm-color-content-secondary)',
57
+ fontWeight: '500'
58
+ }}
59
+ >
60
+ CMD + K
61
+ </kbd>
62
+ <span style={{ fontSize: '14px', color: 'var(--ifm-color-content-secondary)' }}>or</span>
63
+ <kbd
64
+ style={{
65
+ padding: '4px 8px',
66
+ backgroundColor: 'var(--ifm-background-surface-color)',
67
+ borderRadius: 'var(--ifm-code-border-radius)',
68
+ border: '1px solid var(--uc-border-color)',
69
+ boxShadow: 'var(--ifm-global-shadow-lw)',
70
+ fontSize: '12px',
71
+ fontFamily: 'monospace',
72
+ color: 'var(--ifm-color-content-secondary)',
73
+ fontWeight: '500'
74
+ }}
75
+ >
76
+ Ctrl + K
77
+ </kbd>
78
+ <span style={{ fontSize: '14px', fontWeight: '500', color: 'var(--ifm-color-content)' }}>to open the Developer Toolbox</span>
79
+ </div>
80
+ </PlaygroundCard>
81
+ );
82
+ };
83
+
84
+ export default DeveloperToolboxExperience;