@eventcatalog/core 3.0.0 → 3.1.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.
- package/dist/analytics/analytics.cjs +1 -1
- package/dist/analytics/analytics.js +2 -2
- package/dist/analytics/log-build.cjs +1 -1
- package/dist/analytics/log-build.js +3 -3
- package/dist/{chunk-E5Q7TZYT.js → chunk-2WGZFERB.js} +1 -1
- package/dist/{chunk-VO5WYA44.js → chunk-ESUL7UE6.js} +1 -1
- package/dist/{chunk-KF5PARQK.js → chunk-I3CW5KQI.js} +1 -1
- package/dist/{chunk-EKGR533N.js → chunk-KBO4IL2D.js} +1 -1
- package/dist/{chunk-BYP43AAT.js → chunk-URR33SNK.js} +1 -1
- package/dist/constants.cjs +1 -1
- package/dist/constants.js +1 -1
- package/dist/eventcatalog.cjs +1 -1
- package/dist/eventcatalog.config.d.cts +7 -0
- package/dist/eventcatalog.config.d.ts +7 -0
- package/dist/eventcatalog.js +5 -5
- package/dist/generate.cjs +1 -1
- package/dist/generate.js +3 -3
- package/dist/utils/cli-logger.cjs +1 -1
- package/dist/utils/cli-logger.js +2 -2
- package/eventcatalog/src/components/ChatPanel/ChatPanel.tsx +85 -69
- package/eventcatalog/src/components/ChatPanel/ChatPanelButton.tsx +1 -1
- package/eventcatalog/src/components/Checkbox.astro +7 -4
- package/eventcatalog/src/components/CopyAsMarkdown.tsx +15 -15
- package/eventcatalog/src/components/EnvironmentDropdown.tsx +15 -7
- package/eventcatalog/src/components/FavoriteButton.tsx +1 -1
- package/eventcatalog/src/components/Grids/DomainGrid.tsx +72 -60
- package/eventcatalog/src/components/Grids/MessageGrid.tsx +68 -48
- package/eventcatalog/src/components/Header.astro +15 -10
- package/eventcatalog/src/components/Lists/OwnersList.tsx +17 -10
- package/eventcatalog/src/components/Lists/PillListFlat.styles.css +12 -0
- package/eventcatalog/src/components/Lists/PillListFlat.tsx +15 -15
- package/eventcatalog/src/components/Lists/VersionList.astro +15 -5
- package/eventcatalog/src/components/MDX/Accordion/Accordion.tsx +3 -3
- package/eventcatalog/src/components/MDX/Admonition.tsx +49 -9
- package/eventcatalog/src/components/MDX/Attachments.astro +15 -11
- package/eventcatalog/src/components/MDX/ChannelInformation/ChannelInformation.tsx +29 -15
- package/eventcatalog/src/components/MDX/EntityPropertiesTable/EntityPropertiesTable.astro +20 -13
- package/eventcatalog/src/components/MDX/Link/Link.astro +1 -1
- package/eventcatalog/src/components/MDX/MessageTable/MessageTable.client.tsx +50 -29
- package/eventcatalog/src/components/MDX/NodeGraph/NodeGraph.tsx +14 -12
- package/eventcatalog/src/components/MDX/NodeGraph/StepWalkthrough.tsx +4 -4
- package/eventcatalog/src/components/MDX/NodeGraph/StudioModal.tsx +4 -4
- package/eventcatalog/src/components/MDX/NodeGraph/VisualiserSearch.tsx +2 -2
- package/eventcatalog/src/components/MDX/ResourceGroupTable/ResourceGroupTable.client.tsx +54 -33
- package/eventcatalog/src/components/MDX/ResourceLink/ResourceLink.astro +1 -1
- package/eventcatalog/src/components/MDX/Steps/Step.astro +2 -2
- package/eventcatalog/src/components/MDX/Steps/Steps.astro +3 -3
- package/eventcatalog/src/components/MDX/Tabs/Tabs.astro +13 -9
- package/eventcatalog/src/components/MDX/Tiles/Tile.astro +25 -13
- package/eventcatalog/src/components/MDX/Tiles/Tiles.astro +1 -1
- package/eventcatalog/src/components/SchemaExplorer/ApiAccessSection.tsx +3 -3
- package/eventcatalog/src/components/SchemaExplorer/ApiContentViewer.tsx +3 -3
- package/eventcatalog/src/components/SchemaExplorer/AvroSchemaViewer.tsx +29 -25
- package/eventcatalog/src/components/SchemaExplorer/DiffViewer.tsx +3 -3
- package/eventcatalog/src/components/SchemaExplorer/JSONSchemaViewer.tsx +61 -42
- package/eventcatalog/src/components/SchemaExplorer/OwnersSection.tsx +13 -9
- package/eventcatalog/src/components/SchemaExplorer/Pagination.tsx +6 -4
- package/eventcatalog/src/components/SchemaExplorer/ProducersConsumersSection.tsx +17 -13
- package/eventcatalog/src/components/SchemaExplorer/SchemaContentViewer.tsx +35 -8
- package/eventcatalog/src/components/SchemaExplorer/SchemaDetailsHeader.tsx +33 -21
- package/eventcatalog/src/components/SchemaExplorer/SchemaDetailsPanel.tsx +1 -1
- package/eventcatalog/src/components/SchemaExplorer/SchemaExplorer.tsx +41 -33
- package/eventcatalog/src/components/SchemaExplorer/SchemaListItem.tsx +19 -7
- package/eventcatalog/src/components/SchemaExplorer/SchemaViewerModal.tsx +8 -8
- package/eventcatalog/src/components/Search/Search.astro +3 -3
- package/eventcatalog/src/components/Search/SearchModal.tsx +65 -36
- package/eventcatalog/src/components/SideNav/NestedSideBar/SearchBar.tsx +31 -21
- package/eventcatalog/src/components/SideNav/NestedSideBar/index.tsx +92 -59
- package/eventcatalog/src/components/Tables/Table.tsx +25 -24
- package/eventcatalog/src/components/Tables/columns/ContainersTableColumns.tsx +22 -16
- package/eventcatalog/src/components/Tables/columns/DomainTableColumns.tsx +14 -11
- package/eventcatalog/src/components/Tables/columns/FlowTableColumns.tsx +6 -6
- package/eventcatalog/src/components/Tables/columns/MessageTableColumns.tsx +22 -16
- package/eventcatalog/src/components/Tables/columns/ServiceTableColumns.tsx +22 -16
- package/eventcatalog/src/components/Tables/columns/SharedColumns.tsx +4 -4
- package/eventcatalog/src/components/Tables/columns/TeamsTableColumns.tsx +21 -13
- package/eventcatalog/src/components/Tables/columns/UserTableColumns.tsx +30 -19
- package/eventcatalog/src/components/ThemeToggle.tsx +18 -0
- package/eventcatalog/src/enterprise/custom-documentation/components/CustomDocsNav/components/NestedItem.tsx +15 -7
- package/eventcatalog/src/enterprise/custom-documentation/components/CustomDocsNav/components/NoResultsFound.tsx +2 -2
- package/eventcatalog/src/enterprise/custom-documentation/components/CustomDocsNav/index.tsx +19 -15
- package/eventcatalog/src/enterprise/custom-documentation/pages/docs/custom/index.astro +50 -17
- package/eventcatalog/src/layouts/DirectoryLayout.astro +11 -6
- package/eventcatalog/src/layouts/DiscoverLayout.astro +13 -8
- package/eventcatalog/src/layouts/Footer.astro +6 -6
- package/eventcatalog/src/layouts/VerticalSideBarLayout.astro +62 -14
- package/eventcatalog/src/pages/_index.astro +135 -179
- package/eventcatalog/src/pages/architecture/[type]/[id]/[version]/index.astro +2 -2
- package/eventcatalog/src/pages/docs/[type]/[id]/[version]/graphql/[filename].astro +4 -4
- package/eventcatalog/src/pages/docs/[type]/[id]/[version]/index.astro +77 -63
- package/eventcatalog/src/pages/docs/[type]/[id]/language/[dictionaryId]/index.astro +23 -24
- package/eventcatalog/src/pages/docs/[type]/[id]/language/index.astro +66 -50
- package/eventcatalog/src/pages/docs/custom/index.astro +2 -2
- package/eventcatalog/src/pages/docs/teams/[id]/index.astro +25 -21
- package/eventcatalog/src/pages/docs/users/[id]/index.astro +25 -21
- package/eventcatalog/src/pages/schemas/explorer/index.astro +1 -1
- package/eventcatalog/src/pages/studio.astro +59 -31
- package/eventcatalog/src/remark-plugins/directives.ts +6 -6
- package/eventcatalog/src/remark-plugins/mermaid.ts +2 -2
- package/eventcatalog/src/stores/theme-store.ts +93 -0
- package/eventcatalog/src/styles/theme.css +255 -0
- package/eventcatalog/src/styles/themes/forest.css +230 -0
- package/eventcatalog/src/styles/themes/ocean.css +235 -0
- package/eventcatalog/src/styles/themes/sapphire.css +230 -0
- package/eventcatalog/src/styles/themes/sunset.css +230 -0
- package/eventcatalog/src/utils/feature.ts +4 -0
- package/eventcatalog/tailwind.config.mjs +6 -3
- package/package.json +1 -1
|
@@ -487,17 +487,17 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
487
487
|
<div className="flex-none border-b border-gray-100 shrink-0 pb-1">
|
|
488
488
|
<div className="flex items-center justify-between px-4 py-3">
|
|
489
489
|
<div className="flex items-center space-x-2">
|
|
490
|
-
<div className="p-1.5 bg-
|
|
491
|
-
<BookOpen size={14} className="text-
|
|
490
|
+
<div className="p-1.5 bg-[rgb(var(--ec-accent-subtle))] rounded-md">
|
|
491
|
+
<BookOpen size={14} className="text-[rgb(var(--ec-accent))]" />
|
|
492
492
|
</div>
|
|
493
|
-
<span className="font-medium text-
|
|
493
|
+
<span className="font-medium text-[rgb(var(--ec-page-text))] text-sm">EventCatalog Assistant</span>
|
|
494
494
|
</div>
|
|
495
495
|
<div className="flex items-center space-x-1">
|
|
496
496
|
{tools.length > 0 && (
|
|
497
497
|
<Popover.Root>
|
|
498
498
|
<Popover.Trigger asChild>
|
|
499
499
|
<button
|
|
500
|
-
className="p-2 rounded-lg hover:bg-
|
|
500
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
501
501
|
aria-label="View available tools"
|
|
502
502
|
title="Available tools"
|
|
503
503
|
>
|
|
@@ -506,34 +506,36 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
506
506
|
</Popover.Trigger>
|
|
507
507
|
<Popover.Portal>
|
|
508
508
|
<Popover.Content
|
|
509
|
-
className="w-72 bg-
|
|
509
|
+
className="w-72 bg-[rgb(var(--ec-dropdown-bg))] rounded-lg shadow-lg border border-[rgb(var(--ec-dropdown-border))] p-3 z-[250]"
|
|
510
510
|
sideOffset={5}
|
|
511
511
|
align="end"
|
|
512
512
|
>
|
|
513
|
-
<div className="text-[10px] font-medium text-
|
|
514
|
-
|
|
513
|
+
<div className="text-[10px] font-medium text-[rgb(var(--ec-page-text-muted))] mb-2">
|
|
514
|
+
Available Tools ({sortedTools.length})
|
|
515
|
+
</div>
|
|
516
|
+
<div className="max-h-64 overflow-y-auto divide-y divide-[rgb(var(--ec-page-border))]">
|
|
515
517
|
{sortedTools.map((tool) => (
|
|
516
518
|
<div key={tool.name} className="py-1.5 first:pt-0 last:pb-0">
|
|
517
519
|
<div className="flex items-center gap-1.5">
|
|
518
|
-
<span className="text-[11px] font-medium text-
|
|
520
|
+
<span className="text-[11px] font-medium text-[rgb(var(--ec-dropdown-text))]">{tool.name}</span>
|
|
519
521
|
{tool.isCustom && (
|
|
520
|
-
<span className="px-1.5 py-0.5 text-[9px] font-medium bg-
|
|
522
|
+
<span className="px-1.5 py-0.5 text-[9px] font-medium bg-[rgb(var(--ec-accent-subtle))] text-[rgb(var(--ec-accent-text))] rounded">
|
|
521
523
|
Custom
|
|
522
524
|
</span>
|
|
523
525
|
)}
|
|
524
526
|
</div>
|
|
525
|
-
<div className="text-[10px] text-
|
|
527
|
+
<div className="text-[10px] text-[rgb(var(--ec-page-text-muted))] mt-0.5">{tool.description}</div>
|
|
526
528
|
</div>
|
|
527
529
|
))}
|
|
528
530
|
</div>
|
|
529
|
-
<Popover.Arrow className="fill-
|
|
531
|
+
<Popover.Arrow className="fill-[rgb(var(--ec-dropdown-bg))]" />
|
|
530
532
|
</Popover.Content>
|
|
531
533
|
</Popover.Portal>
|
|
532
534
|
</Popover.Root>
|
|
533
535
|
)}
|
|
534
536
|
<button
|
|
535
537
|
onClick={() => setIsFullscreen(true)}
|
|
536
|
-
className="p-2 rounded-lg hover:bg-
|
|
538
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
537
539
|
aria-label="Expand to fullscreen"
|
|
538
540
|
title="Expand"
|
|
539
541
|
>
|
|
@@ -542,7 +544,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
542
544
|
{hasMessages && (
|
|
543
545
|
<button
|
|
544
546
|
onClick={() => setMessages([])}
|
|
545
|
-
className="p-2 rounded-lg hover:bg-
|
|
547
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
546
548
|
aria-label="Clear chat"
|
|
547
549
|
title="Clear chat"
|
|
548
550
|
>
|
|
@@ -551,7 +553,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
551
553
|
)}
|
|
552
554
|
<button
|
|
553
555
|
onClick={onClose}
|
|
554
|
-
className="p-2 rounded-lg hover:bg-
|
|
556
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
555
557
|
aria-label="Close chat panel"
|
|
556
558
|
>
|
|
557
559
|
<X size={18} />
|
|
@@ -561,8 +563,8 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
561
563
|
{/* Thinking indicator */}
|
|
562
564
|
{isThinking && (
|
|
563
565
|
<div className="px-4 pb-2 flex items-center gap-2">
|
|
564
|
-
<div className="w-1.5 h-1.5 bg-
|
|
565
|
-
<span className="text-xs text-
|
|
566
|
+
<div className="w-1.5 h-1.5 bg-[rgb(var(--ec-accent-subtle))]0 rounded-full animate-pulse" />
|
|
567
|
+
<span className="text-xs text-[rgb(var(--ec-page-text-muted))]">Thinking...</span>
|
|
566
568
|
</div>
|
|
567
569
|
)}
|
|
568
570
|
</div>
|
|
@@ -581,20 +583,22 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
581
583
|
>
|
|
582
584
|
{/* Animated Icon */}
|
|
583
585
|
<div className="relative mb-5">
|
|
584
|
-
<div className="absolute inset-0 bg-
|
|
585
|
-
<div className="relative w-14 h-14 rounded-2xl bg-gradient-to-br from-
|
|
586
|
+
<div className="absolute inset-0 bg-[rgb(var(--ec-accent)/0.2)] rounded-2xl blur-xl animate-pulse" />
|
|
587
|
+
<div className="relative w-14 h-14 rounded-2xl bg-gradient-to-br from-[rgb(var(--ec-accent-gradient-from))] to-[rgb(var(--ec-accent-gradient-to))] flex items-center justify-center shadow-lg">
|
|
586
588
|
<BookOpen size={26} className="text-white" strokeWidth={1.5} />
|
|
587
|
-
<Sparkles size={10} className="text-
|
|
589
|
+
<Sparkles size={10} className="text-[rgb(var(--ec-accent)/0.4)] absolute -top-1 -right-1 animate-pulse" />
|
|
588
590
|
</div>
|
|
589
591
|
</div>
|
|
590
|
-
<h2 className="text-base font-medium text-
|
|
591
|
-
<p className="text-sm text-
|
|
592
|
+
<h2 className="text-base font-medium text-[rgb(var(--ec-page-text))] mb-1">{getGreeting()}</h2>
|
|
593
|
+
<p className="text-sm text-[rgb(var(--ec-page-text-muted))] text-center">
|
|
594
|
+
Ask me anything about your catalog.
|
|
595
|
+
</p>
|
|
592
596
|
</div>
|
|
593
597
|
|
|
594
598
|
{/* Suggested questions */}
|
|
595
599
|
<div className="space-y-1.5 mt-4">
|
|
596
600
|
<p
|
|
597
|
-
className="text-xs font-medium text-
|
|
601
|
+
className="text-xs font-medium text-[rgb(var(--ec-page-text-muted))] uppercase tracking-wide mb-2"
|
|
598
602
|
style={isOpen ? fadeInStyles.questionsLabel : undefined}
|
|
599
603
|
>
|
|
600
604
|
Example questions
|
|
@@ -603,7 +607,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
603
607
|
<button
|
|
604
608
|
key={index}
|
|
605
609
|
onClick={() => handleSuggestedAction(question.prompt)}
|
|
606
|
-
className="w-full text-left px-3 py-2.5 text-sm text-
|
|
610
|
+
className="w-full text-left px-3 py-2.5 text-sm text-[rgb(var(--ec-page-text-muted))] bg-[rgb(var(--ec-content-hover))] hover:bg-[rgb(var(--ec-accent-subtle))] hover:text-[rgb(var(--ec-accent-text))] border border-[rgb(var(--ec-page-border))] hover:border-[rgb(var(--ec-accent)/0.3)] rounded-lg transition-colors"
|
|
607
611
|
style={isOpen ? fadeInStyles.getQuestionStyle(index) : undefined}
|
|
608
612
|
>
|
|
609
613
|
{question.label}
|
|
@@ -619,11 +623,11 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
619
623
|
return (
|
|
620
624
|
<div key={message.id} className={`flex ${message.role === 'user' ? 'justify-end' : 'justify-start'}`}>
|
|
621
625
|
{message.role === 'user' ? (
|
|
622
|
-
<div className="max-w-[85%] rounded-2xl rounded-br-md px-4 py-2.5 bg-
|
|
626
|
+
<div className="max-w-[85%] rounded-2xl rounded-br-md px-4 py-2.5 bg-[rgb(var(--ec-accent))] text-white">
|
|
623
627
|
<p className="text-sm whitespace-pre-wrap">{content}</p>
|
|
624
628
|
</div>
|
|
625
629
|
) : (
|
|
626
|
-
<div className="w-full text-
|
|
630
|
+
<div className="w-full text-[rgb(var(--ec-page-text))]">
|
|
627
631
|
<div className="prose prose-sm max-w-none prose-p:my-2 prose-p:font-normal prose-p:text-[13px] prose-headings:my-3 prose-headings:font-medium prose-ul:my-2 prose-ol:my-2 prose-li:my-0.5 prose-li:text-[13px] prose-li:font-normal text-[13px] font-light">
|
|
628
632
|
<ReactMarkdown
|
|
629
633
|
components={{
|
|
@@ -632,7 +636,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
632
636
|
{...props}
|
|
633
637
|
target="_blank"
|
|
634
638
|
rel="noopener noreferrer"
|
|
635
|
-
className="text-
|
|
639
|
+
className="text-[rgb(var(--ec-accent))] hover:text-[rgb(var(--ec-accent-hover))] underline"
|
|
636
640
|
/>
|
|
637
641
|
),
|
|
638
642
|
code: ({ children, className, ...props }) => {
|
|
@@ -643,7 +647,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
643
647
|
|
|
644
648
|
return isInline ? (
|
|
645
649
|
<code
|
|
646
|
-
className="px-1 py-0.5 rounded text-xs font-mono bg-
|
|
650
|
+
className="px-1 py-0.5 rounded text-xs font-mono bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-page-text))]"
|
|
647
651
|
{...props}
|
|
648
652
|
>
|
|
649
653
|
{children}
|
|
@@ -688,9 +692,12 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
688
692
|
</div>
|
|
689
693
|
|
|
690
694
|
{/* Input area (Fixed at bottom) */}
|
|
691
|
-
<div
|
|
695
|
+
<div
|
|
696
|
+
className="flex-none px-4 py-3 border-t border-[rgb(var(--ec-page-border))]"
|
|
697
|
+
key={isOpen ? 'input-open' : 'input-closed'}
|
|
698
|
+
>
|
|
692
699
|
<form onSubmit={handleSubmit}>
|
|
693
|
-
<div className="relative bg-
|
|
700
|
+
<div className="relative bg-[rgb(var(--ec-input-bg))] rounded-lg border-2 border-[rgb(var(--ec-input-border))] focus-within:border-[rgb(var(--ec-accent)/0.5)] transition-all">
|
|
694
701
|
<input
|
|
695
702
|
ref={inputRef}
|
|
696
703
|
type="text"
|
|
@@ -704,14 +711,14 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
704
711
|
}}
|
|
705
712
|
placeholder="Ask a question..."
|
|
706
713
|
disabled={isLoading}
|
|
707
|
-
className="w-full px-3 py-2.5 pr-14 bg-transparent text-
|
|
714
|
+
className="w-full px-3 py-2.5 pr-14 bg-transparent text-[rgb(var(--ec-input-text))] placeholder-[rgb(var(--ec-input-placeholder))] focus:outline-none text-sm disabled:opacity-50 rounded-lg"
|
|
708
715
|
/>
|
|
709
716
|
<div className="absolute right-1.5 top-1/2 -translate-y-1/2 z-10">
|
|
710
717
|
{isStreaming ? (
|
|
711
718
|
<button
|
|
712
719
|
type="button"
|
|
713
720
|
onClick={() => stop()}
|
|
714
|
-
className="p-1.5 text-red-500 hover:bg-red-50 rounded-md transition-colors"
|
|
721
|
+
className="p-1.5 text-red-500 hover:bg-red-50 dark:hover:bg-red-500/10 rounded-md transition-colors"
|
|
715
722
|
aria-label="Stop generating"
|
|
716
723
|
>
|
|
717
724
|
<Square size={12} fill="currentColor" />
|
|
@@ -720,7 +727,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
720
727
|
<button
|
|
721
728
|
type="submit"
|
|
722
729
|
disabled={!inputValue.trim() || isLoading}
|
|
723
|
-
className="px-2.5 py-1 bg-
|
|
730
|
+
className="px-2.5 py-1 bg-[rgb(var(--ec-accent))] text-white text-xs font-medium rounded-md hover:bg-[rgb(var(--ec-accent-hover))] disabled:bg-[rgb(var(--ec-content-hover))] disabled:text-[rgb(var(--ec-icon-color))] transition-colors"
|
|
724
731
|
aria-label="Send message"
|
|
725
732
|
>
|
|
726
733
|
Send
|
|
@@ -729,7 +736,9 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
729
736
|
</div>
|
|
730
737
|
</div>
|
|
731
738
|
</form>
|
|
732
|
-
<p className="text-[9px] text-
|
|
739
|
+
<p className="text-[9px] text-[rgb(var(--ec-icon-color))] mt-2 text-center">
|
|
740
|
+
AI can make mistakes. Verify important info.
|
|
741
|
+
</p>
|
|
733
742
|
</div>
|
|
734
743
|
</div>
|
|
735
744
|
</div>
|
|
@@ -747,22 +756,22 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
747
756
|
}}
|
|
748
757
|
>
|
|
749
758
|
<Dialog.Portal>
|
|
750
|
-
<Dialog.Overlay className="fixed inset-0 bg-
|
|
751
|
-
<Dialog.Content className="fixed inset-y-4 left-1/2 -translate-x-1/2 w-[95%] max-w-4xl md:inset-y-8 rounded-xl bg-
|
|
759
|
+
<Dialog.Overlay className="fixed inset-0 bg-black/50 backdrop-blur-sm z-[300]" />
|
|
760
|
+
<Dialog.Content className="fixed inset-y-4 left-1/2 -translate-x-1/2 w-[95%] max-w-4xl md:inset-y-8 rounded-xl bg-[rgb(var(--ec-page-bg))] shadow-2xl z-[301] flex flex-col overflow-hidden focus:outline-none border border-[rgb(var(--ec-page-border))]">
|
|
752
761
|
{/* Modal Header */}
|
|
753
|
-
<div className="flex items-center justify-between px-5 py-3 border-b border-
|
|
762
|
+
<div className="flex items-center justify-between px-5 py-3 border-b border-[rgb(var(--ec-page-border))] flex-shrink-0">
|
|
754
763
|
<div className="flex items-center space-x-2.5">
|
|
755
|
-
<div className="p-1.5 bg-
|
|
756
|
-
<BookOpen size={18} className="text-
|
|
764
|
+
<div className="p-1.5 bg-[rgb(var(--ec-accent-subtle))] rounded-lg">
|
|
765
|
+
<BookOpen size={18} className="text-[rgb(var(--ec-accent))]" />
|
|
757
766
|
</div>
|
|
758
|
-
<Dialog.Title className="text-base font-medium text-
|
|
767
|
+
<Dialog.Title className="text-base font-medium text-[rgb(var(--ec-page-text))]">Ask AI</Dialog.Title>
|
|
759
768
|
</div>
|
|
760
769
|
<div className="flex items-center space-x-2">
|
|
761
770
|
{tools.length > 0 && (
|
|
762
771
|
<Popover.Root>
|
|
763
772
|
<Popover.Trigger asChild>
|
|
764
773
|
<button
|
|
765
|
-
className="p-2 rounded-lg hover:bg-
|
|
774
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
766
775
|
aria-label="View available tools"
|
|
767
776
|
title="Available tools"
|
|
768
777
|
>
|
|
@@ -771,28 +780,33 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
771
780
|
</Popover.Trigger>
|
|
772
781
|
<Popover.Portal>
|
|
773
782
|
<Popover.Content
|
|
774
|
-
className="w-80 bg-
|
|
783
|
+
className="w-80 bg-[rgb(var(--ec-dropdown-bg))] rounded-lg shadow-lg border border-[rgb(var(--ec-dropdown-border))] p-4 z-[350]"
|
|
775
784
|
sideOffset={5}
|
|
776
785
|
align="end"
|
|
777
786
|
style={{ maxHeight: 'calc(100vh - 200px)' }}
|
|
778
787
|
>
|
|
779
|
-
<div className="text-[11px] font-medium text-
|
|
780
|
-
|
|
788
|
+
<div className="text-[11px] font-medium text-[rgb(var(--ec-page-text-muted))] mb-2">
|
|
789
|
+
Available Tools ({sortedTools.length})
|
|
790
|
+
</div>
|
|
791
|
+
<div
|
|
792
|
+
className="overflow-y-auto divide-y divide-[rgb(var(--ec-page-border))]"
|
|
793
|
+
style={{ maxHeight: 'calc(100vh - 280px)' }}
|
|
794
|
+
>
|
|
781
795
|
{sortedTools.map((tool) => (
|
|
782
796
|
<div key={tool.name} className="py-2 first:pt-0 last:pb-0">
|
|
783
797
|
<div className="flex items-center gap-1.5">
|
|
784
|
-
<span className="text-xs font-medium text-
|
|
798
|
+
<span className="text-xs font-medium text-[rgb(var(--ec-dropdown-text))]">{tool.name}</span>
|
|
785
799
|
{tool.isCustom && (
|
|
786
|
-
<span className="px-1.5 py-0.5 text-[9px] font-medium bg-
|
|
800
|
+
<span className="px-1.5 py-0.5 text-[9px] font-medium bg-[rgb(var(--ec-accent-subtle))] text-[rgb(var(--ec-accent-text))] rounded">
|
|
787
801
|
Custom
|
|
788
802
|
</span>
|
|
789
803
|
)}
|
|
790
804
|
</div>
|
|
791
|
-
<div className="text-[11px] text-
|
|
805
|
+
<div className="text-[11px] text-[rgb(var(--ec-page-text-muted))] mt-0.5">{tool.description}</div>
|
|
792
806
|
</div>
|
|
793
807
|
))}
|
|
794
808
|
</div>
|
|
795
|
-
<Popover.Arrow className="fill-
|
|
809
|
+
<Popover.Arrow className="fill-[rgb(var(--ec-dropdown-bg))]" />
|
|
796
810
|
</Popover.Content>
|
|
797
811
|
</Popover.Portal>
|
|
798
812
|
</Popover.Root>
|
|
@@ -800,7 +814,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
800
814
|
{hasMessages && (
|
|
801
815
|
<button
|
|
802
816
|
onClick={() => setMessages([])}
|
|
803
|
-
className="p-2 rounded-lg hover:bg-
|
|
817
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
804
818
|
aria-label="Clear chat"
|
|
805
819
|
title="Clear chat"
|
|
806
820
|
>
|
|
@@ -809,7 +823,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
809
823
|
)}
|
|
810
824
|
<button
|
|
811
825
|
onClick={() => setIsFullscreen(false)}
|
|
812
|
-
className="p-2 rounded-lg hover:bg-
|
|
826
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
813
827
|
aria-label="Exit fullscreen"
|
|
814
828
|
title="Exit fullscreen"
|
|
815
829
|
>
|
|
@@ -820,7 +834,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
820
834
|
setIsFullscreen(false);
|
|
821
835
|
onClose();
|
|
822
836
|
}}
|
|
823
|
-
className="p-2 rounded-lg hover:bg-
|
|
837
|
+
className="p-2 rounded-lg hover:bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-icon-color))] hover:text-[rgb(var(--ec-page-text))] transition-colors"
|
|
824
838
|
aria-label="Close"
|
|
825
839
|
>
|
|
826
840
|
<X size={18} />
|
|
@@ -830,9 +844,9 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
830
844
|
|
|
831
845
|
{/* Thinking indicator */}
|
|
832
846
|
{isThinking && (
|
|
833
|
-
<div className="px-5 py-2 flex items-center gap-2 border-b border-
|
|
834
|
-
<div className="w-1.5 h-1.5 bg-
|
|
835
|
-
<span className="text-sm text-
|
|
847
|
+
<div className="px-5 py-2 flex items-center gap-2 border-b border-[rgb(var(--ec-page-border))]">
|
|
848
|
+
<div className="w-1.5 h-1.5 bg-[rgb(var(--ec-accent-subtle))]0 rounded-full animate-pulse" />
|
|
849
|
+
<span className="text-sm text-[rgb(var(--ec-page-text-muted))]">Thinking...</span>
|
|
836
850
|
</div>
|
|
837
851
|
)}
|
|
838
852
|
|
|
@@ -843,14 +857,14 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
843
857
|
<div className="flex flex-col h-full justify-center items-center">
|
|
844
858
|
{/* Animated Icon */}
|
|
845
859
|
<div className="relative mb-6">
|
|
846
|
-
<div className="absolute inset-0 bg-
|
|
847
|
-
<div className="relative w-16 h-16 rounded-2xl bg-gradient-to-br from-
|
|
860
|
+
<div className="absolute inset-0 bg-[rgb(var(--ec-accent)/0.2)] rounded-2xl blur-xl animate-pulse" />
|
|
861
|
+
<div className="relative w-16 h-16 rounded-2xl bg-gradient-to-br from-[rgb(var(--ec-accent-gradient-from))] to-[rgb(var(--ec-accent-gradient-to))] flex items-center justify-center shadow-lg">
|
|
848
862
|
<BookOpen size={30} className="text-white" strokeWidth={1.5} />
|
|
849
|
-
<Sparkles size={12} className="text-
|
|
863
|
+
<Sparkles size={12} className="text-[rgb(var(--ec-accent)/0.4)] absolute -top-1 -right-1 animate-pulse" />
|
|
850
864
|
</div>
|
|
851
865
|
</div>
|
|
852
|
-
<h2 className="text-xl font-medium text-
|
|
853
|
-
<p className="text-
|
|
866
|
+
<h2 className="text-xl font-medium text-[rgb(var(--ec-page-text))] mb-1">{getGreeting()}</h2>
|
|
867
|
+
<p className="text-[rgb(var(--ec-page-text-muted))] text-center mb-8">Ask me anything about your catalog.</p>
|
|
854
868
|
|
|
855
869
|
{/* Suggested questions */}
|
|
856
870
|
<div className="grid grid-cols-2 gap-2 max-w-lg">
|
|
@@ -858,7 +872,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
858
872
|
<button
|
|
859
873
|
key={index}
|
|
860
874
|
onClick={() => handleSuggestedAction(question.prompt)}
|
|
861
|
-
className="px-4 py-2.5 text-sm text-
|
|
875
|
+
className="px-4 py-2.5 text-sm text-[rgb(var(--ec-page-text-muted))] bg-[rgb(var(--ec-content-hover))] hover:bg-[rgb(var(--ec-accent-subtle))] hover:text-[rgb(var(--ec-accent-text))] rounded-lg transition-colors text-left"
|
|
862
876
|
>
|
|
863
877
|
{question.label}
|
|
864
878
|
</button>
|
|
@@ -873,11 +887,11 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
873
887
|
return (
|
|
874
888
|
<div key={message.id} className={`flex ${message.role === 'user' ? 'justify-end' : 'justify-start'}`}>
|
|
875
889
|
{message.role === 'user' ? (
|
|
876
|
-
<div className="max-w-[75%] rounded-2xl rounded-br-md px-4 py-2.5 bg-
|
|
890
|
+
<div className="max-w-[75%] rounded-2xl rounded-br-md px-4 py-2.5 bg-[rgb(var(--ec-accent))] text-white">
|
|
877
891
|
<p className="text-sm whitespace-pre-wrap">{content}</p>
|
|
878
892
|
</div>
|
|
879
893
|
) : (
|
|
880
|
-
<div className="w-full text-
|
|
894
|
+
<div className="w-full text-[rgb(var(--ec-page-text))]">
|
|
881
895
|
<div className="prose prose-sm max-w-none">
|
|
882
896
|
<ReactMarkdown
|
|
883
897
|
components={{
|
|
@@ -886,7 +900,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
886
900
|
{...props}
|
|
887
901
|
target="_blank"
|
|
888
902
|
rel="noopener noreferrer"
|
|
889
|
-
className="text-
|
|
903
|
+
className="text-[rgb(var(--ec-accent))] hover:text-[rgb(var(--ec-accent-hover))] underline"
|
|
890
904
|
/>
|
|
891
905
|
),
|
|
892
906
|
code: ({ children, className, ...props }) => {
|
|
@@ -897,7 +911,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
897
911
|
|
|
898
912
|
return isInline ? (
|
|
899
913
|
<code
|
|
900
|
-
className="px-1.5 py-0.5 rounded text-sm font-mono bg-
|
|
914
|
+
className="px-1.5 py-0.5 rounded text-sm font-mono bg-[rgb(var(--ec-content-hover))] text-[rgb(var(--ec-page-text))]"
|
|
901
915
|
{...props}
|
|
902
916
|
>
|
|
903
917
|
{children}
|
|
@@ -941,9 +955,9 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
941
955
|
</div>
|
|
942
956
|
|
|
943
957
|
{/* Modal Input area */}
|
|
944
|
-
<div className="flex-shrink-0 px-5 py-4 border-t border-
|
|
958
|
+
<div className="flex-shrink-0 px-5 py-4 border-t border-[rgb(var(--ec-page-border))]">
|
|
945
959
|
<form onSubmit={handleSubmit} className="max-w-3xl mx-auto">
|
|
946
|
-
<div className="relative bg-
|
|
960
|
+
<div className="relative bg-[rgb(var(--ec-input-bg))] rounded-lg border border-[rgb(var(--ec-input-border))] focus-within:border-[rgb(var(--ec-accent)/0.5)] transition-all">
|
|
947
961
|
<input
|
|
948
962
|
ref={modalInputRef}
|
|
949
963
|
type="text"
|
|
@@ -957,14 +971,14 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
957
971
|
}}
|
|
958
972
|
placeholder="Ask a question..."
|
|
959
973
|
disabled={isLoading}
|
|
960
|
-
className="w-full px-4 py-3 pr-16 bg-transparent text-
|
|
974
|
+
className="w-full px-4 py-3 pr-16 bg-transparent text-[rgb(var(--ec-input-text))] placeholder-[rgb(var(--ec-input-placeholder))] focus:outline-none text-sm disabled:opacity-50 rounded-lg"
|
|
961
975
|
/>
|
|
962
976
|
<div className="absolute right-2 top-1/2 -translate-y-1/2 z-10">
|
|
963
977
|
{isStreaming ? (
|
|
964
978
|
<button
|
|
965
979
|
type="button"
|
|
966
980
|
onClick={() => stop()}
|
|
967
|
-
className="p-1.5 text-red-500 hover:bg-red-50 rounded-md transition-colors"
|
|
981
|
+
className="p-1.5 text-red-500 hover:bg-red-50 dark:hover:bg-red-500/10 rounded-md transition-colors"
|
|
968
982
|
aria-label="Stop generating"
|
|
969
983
|
>
|
|
970
984
|
<Square size={14} fill="currentColor" />
|
|
@@ -973,7 +987,7 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
973
987
|
<button
|
|
974
988
|
type="submit"
|
|
975
989
|
disabled={!inputValue.trim() || isLoading}
|
|
976
|
-
className="px-3 py-1.5 bg-
|
|
990
|
+
className="px-3 py-1.5 bg-[rgb(var(--ec-accent))] text-white text-sm font-medium rounded-md hover:bg-[rgb(var(--ec-accent-hover))] disabled:bg-[rgb(var(--ec-content-hover))] disabled:text-[rgb(var(--ec-icon-color))] disabled:cursor-not-allowed transition-colors"
|
|
977
991
|
aria-label="Send message"
|
|
978
992
|
>
|
|
979
993
|
Send
|
|
@@ -982,7 +996,9 @@ const ChatPanel = ({ isOpen, onClose }: ChatPanelProps) => {
|
|
|
982
996
|
</div>
|
|
983
997
|
</div>
|
|
984
998
|
</form>
|
|
985
|
-
<p className="text-xs text-
|
|
999
|
+
<p className="text-xs text-[rgb(var(--ec-icon-color))] mt-2 text-center">
|
|
1000
|
+
AI can make mistakes. Verify important info.
|
|
1001
|
+
</p>
|
|
986
1002
|
</div>
|
|
987
1003
|
</Dialog.Content>
|
|
988
1004
|
</Dialog.Portal>
|
|
@@ -12,7 +12,7 @@ const ChatPanelButton = () => {
|
|
|
12
12
|
className="flex items-center gap-1.5 px-4 py-1.5 rounded-md bg-white hover:bg-gray-50 ring-1 ring-inset ring-gray-300 shadow-sm transition-colors text-sm ml-[-1px]"
|
|
13
13
|
aria-label="Open AI Assistant"
|
|
14
14
|
>
|
|
15
|
-
<BookOpen size={14} className="text-
|
|
15
|
+
<BookOpen size={14} className="text-[rgb(var(--ec-accent))]" />
|
|
16
16
|
<span className="font-light text-gray-600">Ask</span>
|
|
17
17
|
</button>
|
|
18
18
|
|
|
@@ -12,21 +12,24 @@ const { id, name, label, class: className, ...attrs } = Astro.props;
|
|
|
12
12
|
|
|
13
13
|
<label for={id} class="relative block cursor-pointer select-none pl-5">
|
|
14
14
|
<input id={id} name={name} type="checkbox" class="h-0 w-0 cursor-pointer appearance-none group" {...attrs} />
|
|
15
|
-
<span class="text-md text-
|
|
15
|
+
<span class="text-md text-[rgb(var(--ec-page-text))]">{label}</span>
|
|
16
16
|
</label>
|
|
17
17
|
|
|
18
18
|
<style>
|
|
19
19
|
input::before {
|
|
20
|
-
@apply absolute left-0 top-1/2 block h-4 w-4 -translate-y-1/2 rounded-[4px]
|
|
20
|
+
@apply absolute left-0 top-1/2 block h-4 w-4 -translate-y-1/2 rounded-[4px];
|
|
21
21
|
content: '';
|
|
22
|
+
border: 1px solid rgb(var(--ec-page-border));
|
|
23
|
+
background-color: rgb(var(--ec-input-bg));
|
|
22
24
|
}
|
|
23
25
|
|
|
24
26
|
input:checked::before {
|
|
25
|
-
|
|
27
|
+
background-color: rgb(var(--ec-accent));
|
|
28
|
+
border-color: rgb(var(--ec-accent));
|
|
26
29
|
}
|
|
27
30
|
|
|
28
31
|
input:focus::before {
|
|
29
|
-
|
|
32
|
+
outline: 2px solid rgb(var(--ec-accent) / 0.3);
|
|
30
33
|
}
|
|
31
34
|
|
|
32
35
|
input:checked::after {
|
|
@@ -27,17 +27,17 @@ const MenuItemContent = ({
|
|
|
27
27
|
} else {
|
|
28
28
|
// It must be an ElementType (component constructor like Lucide icon)
|
|
29
29
|
const IconComponent = iconProp as React.ElementType;
|
|
30
|
-
iconElement = <IconComponent className="w-5 h-5 text-
|
|
30
|
+
iconElement = <IconComponent className="w-5 h-5 text-[rgb(var(--ec-icon-color))]" />;
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
return (
|
|
34
34
|
<div className="flex items-center gap-3 px-3 py-2 text-sm">
|
|
35
|
-
<div className="p-1 border border-
|
|
35
|
+
<div className="p-1 border border-[rgb(var(--ec-dropdown-border))] rounded">{iconElement}</div>
|
|
36
36
|
<div className="flex-1">
|
|
37
|
-
<div className="font-medium text-
|
|
38
|
-
<div className="text-xs text-
|
|
37
|
+
<div className="font-medium text-[rgb(var(--ec-dropdown-text))]">{title}</div>
|
|
38
|
+
<div className="text-xs text-[rgb(var(--ec-content-text-muted))]">{description}</div>
|
|
39
39
|
</div>
|
|
40
|
-
{external && <ExternalLink className="w-4 h-4 text-
|
|
40
|
+
{external && <ExternalLink className="w-4 h-4 text-[rgb(var(--ec-icon-color))]" />}
|
|
41
41
|
</div>
|
|
42
42
|
);
|
|
43
43
|
};
|
|
@@ -199,12 +199,12 @@ export function CopyPageMenu({
|
|
|
199
199
|
return (
|
|
200
200
|
<DropdownMenu.Root>
|
|
201
201
|
{/* Container for the split button */}
|
|
202
|
-
<div className="inline-flex rounded-md shadow-sm border border-
|
|
202
|
+
<div className="inline-flex rounded-md shadow-sm border border-[rgb(var(--ec-dropdown-border))]">
|
|
203
203
|
{/* Left Button: Default Action */}
|
|
204
204
|
<button
|
|
205
205
|
type="button"
|
|
206
206
|
onClick={handleDefaultAction}
|
|
207
|
-
className="inline-flex items-center justify-center gap-1 px-3 py-1.5 text-sm font-medium text-
|
|
207
|
+
className="inline-flex items-center justify-center gap-1 px-3 py-1.5 text-sm font-medium text-[rgb(var(--ec-dropdown-text))] bg-[rgb(var(--ec-dropdown-bg))] rounded-l-md hover:bg-[rgb(var(--ec-dropdown-hover))] focus:z-10 focus:outline-none focus:ring-1 focus:ring-[rgb(var(--ec-accent))]"
|
|
208
208
|
>
|
|
209
209
|
<defaultAction.icon className="w-4 h-4" />
|
|
210
210
|
{buttonText}
|
|
@@ -213,7 +213,7 @@ export function CopyPageMenu({
|
|
|
213
213
|
<DropdownMenu.Trigger asChild>
|
|
214
214
|
<button
|
|
215
215
|
type="button"
|
|
216
|
-
className="inline-flex items-center justify-center px-1.5 py-1.5 text-sm font-medium text-
|
|
216
|
+
className="inline-flex items-center justify-center px-1.5 py-1.5 text-sm font-medium text-[rgb(var(--ec-icon-color))] bg-[rgb(var(--ec-dropdown-bg))] rounded-r-md border-l border-[rgb(var(--ec-dropdown-border))] hover:bg-[rgb(var(--ec-dropdown-hover))] focus:z-10 focus:outline-none focus:ring-1 focus:ring-[rgb(var(--ec-accent))]"
|
|
217
217
|
aria-label="More options"
|
|
218
218
|
>
|
|
219
219
|
<ChevronDownIcon className="w-4 h-4" />
|
|
@@ -223,13 +223,13 @@ export function CopyPageMenu({
|
|
|
223
223
|
|
|
224
224
|
{/* Adjust styling for the content dropdown */}
|
|
225
225
|
<DropdownMenu.Content
|
|
226
|
-
className="w-72 bg-
|
|
226
|
+
className="w-72 bg-[rgb(var(--ec-dropdown-bg))] rounded-lg shadow-lg border border-[rgb(var(--ec-dropdown-border))] mt-1 py-1"
|
|
227
227
|
sideOffset={5}
|
|
228
228
|
align="end"
|
|
229
229
|
>
|
|
230
230
|
{availableActions.copyMarkdown && (
|
|
231
231
|
<DropdownMenu.Item
|
|
232
|
-
className="cursor-pointer hover:bg-
|
|
232
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
233
233
|
onSelect={() => copyMarkdownToClipboard()}
|
|
234
234
|
>
|
|
235
235
|
<MenuItemContent icon={Copy} title="Copy page" description="Copy page as Markdown for LLMs" />
|
|
@@ -238,7 +238,7 @@ export function CopyPageMenu({
|
|
|
238
238
|
|
|
239
239
|
{availableActions.editPage && (
|
|
240
240
|
<DropdownMenu.Item
|
|
241
|
-
className="cursor-pointer hover:bg-
|
|
241
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
242
242
|
onSelect={() => window.open(editUrl, '_blank')}
|
|
243
243
|
>
|
|
244
244
|
<MenuItemContent
|
|
@@ -275,7 +275,7 @@ export function CopyPageMenu({
|
|
|
275
275
|
return (
|
|
276
276
|
<DropdownMenu.Item
|
|
277
277
|
key={schema.url}
|
|
278
|
-
className="cursor-pointer hover:bg-
|
|
278
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
279
279
|
onSelect={() => copySchemaToClipboard(schema)}
|
|
280
280
|
>
|
|
281
281
|
<MenuItemContent icon={Icon} title={title} description={`Copy ${type} to clipboard`} />
|
|
@@ -285,7 +285,7 @@ export function CopyPageMenu({
|
|
|
285
285
|
|
|
286
286
|
{availableActions.viewMarkdown && (
|
|
287
287
|
<DropdownMenu.Item
|
|
288
|
-
className="cursor-pointer hover:bg-
|
|
288
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
289
289
|
onSelect={() => window.open(markdownUrl, '_blank')}
|
|
290
290
|
>
|
|
291
291
|
<MenuItemContent
|
|
@@ -299,7 +299,7 @@ export function CopyPageMenu({
|
|
|
299
299
|
|
|
300
300
|
{availableActions.rssFeed && (
|
|
301
301
|
<DropdownMenu.Item
|
|
302
|
-
className="cursor-pointer hover:bg-
|
|
302
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
303
303
|
onSelect={() => window.open(buildUrl(`/rss/all/rss.xml`), '_blank')}
|
|
304
304
|
>
|
|
305
305
|
<MenuItemContent icon={RssIcon} title="RSS Feed" description="View this page as RSS feed" external={true} />
|
|
@@ -307,7 +307,7 @@ export function CopyPageMenu({
|
|
|
307
307
|
)}
|
|
308
308
|
{availableActions.chat && (
|
|
309
309
|
<DropdownMenu.Item
|
|
310
|
-
className="cursor-pointer hover:bg-
|
|
310
|
+
className="cursor-pointer hover:bg-[rgb(var(--ec-dropdown-hover))] focus:outline-none focus:bg-[rgb(var(--ec-dropdown-hover))]"
|
|
311
311
|
onSelect={() => window.open(buildUrl(`/chat`) + `?query=${chatQuery}`)}
|
|
312
312
|
>
|
|
313
313
|
<MenuItemContent
|