@pantheon-systems/pds-toolkit-react 2.0.0-alpha.36 → 2.0.0-alpha.37

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 (77) hide show
  1. package/codemods/v1-to-v2/mappings.json +122 -20
  2. package/dist/components/Callout/Callout.d.ts +6 -2
  3. package/dist/components/CodeBlock/CodeBlock.d.ts +10 -5
  4. package/dist/components/CodeBlock/code-examples.d.ts +1 -0
  5. package/dist/components/CodeBlock/themes/index.d.ts +1 -2
  6. package/dist/components/CodeBlock/themes/{pdsDark.d.ts → pds.d.ts} +1 -1
  7. package/dist/components/PantheonLogo/PantheonLogo.d.ts +5 -4
  8. package/dist/components/Tabs/Tabs.d.ts +1 -6
  9. package/dist/components/badges/StatusBadge/StatusBadge.d.ts +2 -1
  10. package/dist/components/buttons/MenuButton/MenuButton.d.ts +1 -1
  11. package/dist/components/buttons/SegmentedButton/SegmentedButton.d.ts +25 -7
  12. package/dist/components/buttons/SplitButton/SplitButton.d.ts +1 -1
  13. package/dist/components/icons/Icon/generated-icon-data.d.ts +9 -2
  14. package/dist/components/inputs/Combobox/Combobox.d.ts +1 -1
  15. package/dist/components/inputs/ComboboxMultiselect/ComboboxMultiselect.d.ts +1 -1
  16. package/dist/components/inputs/Select/Select.d.ts +1 -1
  17. package/dist/components/inputs/TagsInput/TagsInput.d.ts +1 -1
  18. package/dist/components/inputs/TextInput/TextInput.d.ts +1 -1
  19. package/dist/components/inputs/Textarea/Textarea.d.ts +1 -1
  20. package/dist/components/loading-indicators/Spinner/Spinner.d.ts +5 -4
  21. package/dist/components/navigation/ButtonNav/ButtonNav.d.ts +1 -5
  22. package/dist/components/navigation/Navbar/Navbar.d.ts +2 -23
  23. package/dist/components/navigation/TabMenu/TabMenu.d.ts +1 -6
  24. package/dist/components/navigation/WorkspaceSelector/WorkspaceSelector.d.ts +0 -11
  25. package/dist/components/panels/Panel/Panel.d.ts +1 -1
  26. package/dist/css/component-css/pds-avatar.css +1 -1
  27. package/dist/css/component-css/pds-button-nav.css +1 -1
  28. package/dist/css/component-css/pds-button.css +1 -1
  29. package/dist/css/component-css/pds-callout.css +1 -1
  30. package/dist/css/component-css/pds-card-select.css +1 -1
  31. package/dist/css/component-css/pds-code-block.css +1 -1
  32. package/dist/css/component-css/pds-combobox-multiselect.css +1 -2
  33. package/dist/css/component-css/pds-combobox.css +1 -1
  34. package/dist/css/component-css/pds-datepicker.css +3 -1
  35. package/dist/css/component-css/pds-index.css +42 -36
  36. package/dist/css/component-css/pds-input-utilities.css +1 -1
  37. package/dist/css/component-css/pds-menu-button.css +4 -1
  38. package/dist/css/component-css/pds-nav-menu.css +1 -1
  39. package/dist/css/component-css/pds-navbar.css +2 -2
  40. package/dist/css/component-css/pds-panel.css +1 -1
  41. package/dist/css/component-css/pds-pantheon-logo.css +1 -1
  42. package/dist/css/component-css/pds-popover.css +1 -1
  43. package/dist/css/component-css/pds-segmented-button.css +2 -1
  44. package/dist/css/component-css/pds-select.css +1 -1
  45. package/dist/css/component-css/pds-side-nav-global.css +1 -1
  46. package/dist/css/component-css/pds-side-nav.css +1 -1
  47. package/dist/css/component-css/pds-spinner.css +1 -1
  48. package/dist/css/component-css/pds-split-button.css +1 -1
  49. package/dist/css/component-css/pds-status-badge.css +1 -1
  50. package/dist/css/component-css/pds-status-indicator.css +1 -1
  51. package/dist/css/component-css/pds-tab-menu.css +1 -1
  52. package/dist/css/component-css/pds-tabs.css +1 -1
  53. package/dist/css/component-css/pds-tags-input.css +1 -1
  54. package/dist/css/component-css/pds-text-input.css +1 -1
  55. package/dist/css/component-css/pds-textarea.css +1 -1
  56. package/dist/css/component-css/pds-toaster.css +1 -1
  57. package/dist/css/component-css/pds-user-menu.css +6 -3
  58. package/dist/css/component-css/pds-utility-button.css +1 -1
  59. package/dist/css/component-css/pds-workspace-selector.css +13 -3
  60. package/dist/css/design-tokens/variables.dark.css +26 -21
  61. package/dist/css/design-tokens/variables.light.css +26 -21
  62. package/dist/css/design-tokens/variables.typography.css +0 -1
  63. package/dist/css/pds-components.css +42 -36
  64. package/dist/css/pds-core.css +2 -2
  65. package/dist/index.css +1 -1
  66. package/dist/index.d.ts +1 -2
  67. package/dist/index.js +2318 -1359
  68. package/dist/index.js.map +1 -1
  69. package/dist/index.source.d.ts +0 -2
  70. package/dist/libs/components/NavAccordion/NavAccordion.d.ts +1 -1
  71. package/dist/svg/userSolid.svg +3 -0
  72. package/package.json +2 -2
  73. package/dist/components/CodeBlock/themes/pdsLight.d.ts +0 -2
  74. package/dist/components/notifications/NotificationHubIcon/NotificationHubIcon.d.ts +0 -38
  75. package/dist/components/notifications/NotificationsPopover/NotificationsPopover.d.ts +0 -113
  76. package/dist/css/component-css/pds-notification-hub-icon.css +0 -1
  77. package/dist/css/component-css/pds-notifications-popover.css +0 -13
@@ -68,8 +68,6 @@ export * from './components/navigation/UserMenu/UserMenu';
68
68
  export * from './components/navigation/WorkspaceSelector/WorkspaceSelector';
69
69
  export * from './components/notifications/Banner/Banner';
70
70
  export * from './components/notifications/InlineMessage/InlineMessage';
71
- export * from './components/notifications/NotificationHubIcon/NotificationHubIcon';
72
- export * from './components/notifications/NotificationsPopover/NotificationsPopover';
73
71
  export * from './components/notifications/SectionMessage/SectionMessage';
74
72
  export * from './components/notifications/Toaster/Toast';
75
73
  export * from './components/notifications/Toaster/Toaster';
@@ -21,7 +21,7 @@ interface NavAccordionProps {
21
21
  /**
22
22
  * Internal accordion component for the mobile navbar panel.
23
23
  * Renders a toggle button with a rotating chevron and expandable content.
24
- * Used by MenuButton, UserMenu, WorkspaceSelector, and NotificationsPopover.
24
+ * Used by MenuButton, UserMenu, and WorkspaceSelector.
25
25
  */
26
26
  export declare const NavAccordion: ({ children, className, disabled, label, }: NavAccordionProps) => import("react/jsx-runtime").JSX.Element;
27
27
  export {};
@@ -0,0 +1,3 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" fill="currentColor" aria-hidden="true" focusable="false" role="img">
2
+ <path d="M224 248a120 120 0 1 0 0-240 120 120 0 1 0 0 240zm-29.7 56C95.8 304 16 383.8 16 482.3 16 498.7 29.3 512 45.7 512l356.6 0c16.4 0 29.7-13.3 29.7-29.7 0-98.5-79.8-178.3-178.3-178.3l-59.4 0z"/>
3
+ </svg>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pantheon-systems/pds-toolkit-react",
3
3
  "technology": "React",
4
- "version": "2.0.0-alpha.36",
4
+ "version": "2.0.0-alpha.37",
5
5
  "description": "PDS toolkit built using the React framework",
6
6
  "publishConfig": {
7
7
  "access": "public",
@@ -178,7 +178,7 @@
178
178
  "@dnd-kit/utilities": "^3.2.2",
179
179
  "@floating-ui/react": "^0.24.3",
180
180
  "@floating-ui/react-dom": "~1.3.0",
181
- "@pantheon-systems/pds-design-tokens": "^2.0.0-alpha.51",
181
+ "@pantheon-systems/pds-design-tokens": "^2.0.0-alpha.55",
182
182
  "@reactuses/core": "^5.0.15",
183
183
  "date-fns": "^4.1.0",
184
184
  "downshift": "^9.3.2",
@@ -1,2 +0,0 @@
1
- import type { PrismTheme } from 'prism-react-renderer';
2
- export declare const pdsLight: PrismTheme;
@@ -1,38 +0,0 @@
1
- import { ComponentPropsWithoutRef } from 'react';
2
- import './notification-hub-icon.css';
3
- /**
4
- * Notification categories
5
- */
6
- export type NotificationCategory = 'billing' | 'code-pipeline' | 'deployment' | 'platform';
7
- /**
8
- * Notification type levels
9
- */
10
- export type NotificationType = 'critical' | 'info' | 'warning';
11
- /**
12
- * Prop types for NotificationHubIcon
13
- */
14
- export interface NotificationHubIconProps extends ComponentPropsWithoutRef<'span'> {
15
- /**
16
- * Category of the notification (determines icon)
17
- */
18
- category: NotificationCategory;
19
- /**
20
- * Additional class names
21
- */
22
- className?: string;
23
- /**
24
- * Display variant for the icon
25
- * @default 'inbox'
26
- */
27
- displayType?: 'inbox' | 'popover';
28
- /**
29
- * Type of the notification (determines color)
30
- */
31
- type?: NotificationType;
32
- }
33
- /**
34
- * NotificationHubIcon UI component
35
- *
36
- * Icon representing a notification's category with color based on type.
37
- */
38
- export declare const NotificationHubIcon: ({ category, className, displayType, type, ...props }: NotificationHubIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,113 +0,0 @@
1
- import { ComponentPropsWithoutRef } from 'react';
2
- import { NotificationCategory, NotificationType } from '../../notifications/NotificationHubIcon/NotificationHubIcon';
3
- import './notifications-popover.css';
4
- /**
5
- * Notification item type
6
- */
7
- export type NotificationItem = {
8
- /**
9
- * Category of the notification (determines icon)
10
- */
11
- category: NotificationCategory;
12
- /**
13
- * Unique identifier for the notification
14
- */
15
- id: string;
16
- /**
17
- * Whether the notification has been read
18
- */
19
- read: boolean;
20
- /**
21
- * Optional site name associated with the notification
22
- */
23
- siteName?: string;
24
- /**
25
- * Timestamp of the notification (should be formatted string)
26
- */
27
- timestamp: string;
28
- /**
29
- * Title/message of the notification
30
- */
31
- title: string;
32
- /**
33
- * Type of the notification (determines color)
34
- */
35
- type: NotificationType;
36
- };
37
- /**
38
- * Prop types for NotificationsPopover
39
- */
40
- export interface NotificationsPopoverProps extends ComponentPropsWithoutRef<'span'> {
41
- /**
42
- * Aria label for the trigger button
43
- * @default 'Notifications'
44
- */
45
- ariaLabel?: string;
46
- /**
47
- * Auto-close popover when a notification is clicked
48
- * @default true
49
- */
50
- autoCloseOnClick?: boolean;
51
- /**
52
- * Additional class names
53
- */
54
- className?: string;
55
- /**
56
- * Text to display when there are no notifications
57
- * @default 'No notifications'
58
- */
59
- emptyText?: string;
60
- /**
61
- * Text to display while loading
62
- * @default 'Loading notifications...'
63
- */
64
- loadingText?: string;
65
- /**
66
- * Maximum number of notifications to display in the list
67
- * @default 10
68
- */
69
- maxVisibleItems?: number;
70
- /**
71
- * Heading text for the popover panel
72
- * @default 'Notifications'
73
- */
74
- menuHeading?: string;
75
- /**
76
- * Array of notification items to display
77
- */
78
- notifications?: NotificationItem[];
79
- /**
80
- * Callback function when a notification is clicked
81
- */
82
- onNotificationClick?: (notification: NotificationItem) => void;
83
- /**
84
- * Callback function when the "View All" button is clicked
85
- */
86
- onViewAllClick?: () => void;
87
- /**
88
- * Whether the notifications are currently loading
89
- */
90
- showLoading?: boolean;
91
- /**
92
- * Can be used to show a total number of unread notifications across all notifications (not just visible ones)
93
- * Leave undefined to calculate from the notifications array
94
- * Will use the greater of this value or the calculated count from the notifications array
95
- */
96
- unreadCount?: number;
97
- /**
98
- * Label for unread status (screen reader only)
99
- * @default 'unread'
100
- */
101
- unreadLabel?: string;
102
- /**
103
- * Text for the "View All" button
104
- * @default 'View all notifications'
105
- */
106
- viewAllText?: string;
107
- }
108
- /**
109
- * NotificationsPopover UI component
110
- *
111
- * Bell icon trigger that opens a popover showing recent notifications.
112
- */
113
- export declare const NotificationsPopover: ({ ariaLabel, autoCloseOnClick, className, emptyText, loadingText, maxVisibleItems, menuHeading, notifications, onNotificationClick, onViewAllClick, showLoading, unreadCount, unreadLabel, viewAllText, ...props }: NotificationsPopoverProps) => import("react/jsx-runtime").JSX.Element;
@@ -1 +0,0 @@
1
- .pds-notification-hub-icon{align-items:center;color:var(--fg-color);display:inline-flex;flex-shrink:0;justify-content:center}.pds-notification-hub-icon,.pds-notification-hub-icon--info{--bg-color:var(--pds-color-surface-default-secondary);--border-color:var(--pds-color-border-default);--fg-color:var(--pds-color-foreground-default-secondary)}.pds-notification-hub-icon--warning{--bg-color:var(--pds-color-status-warning-background);--border-color:var(--pds-color-status-warning-border);--fg-color:var(--pds-color-status-warning-foreground)}.pds-notification-hub-icon--critical{--bg-color:var(--pds-color-status-critical-background);--border-color:var(--pds-color-status-critical-border);--fg-color:var(--pds-color-status-critical-foreground)}.pds-notification-hub-icon--popover{background-color:var(--bg-color);border:var(--pds-border-width-default) solid var(--border-color);border-radius:50%;height:var(--pds-spacing-3xl);width:var(--pds-spacing-3xl)}.pds-notification-hub-icon--popover .pds-icon--codeBranch{padding-inline-start:.125rem}
@@ -1,13 +0,0 @@
1
- .pds-notifications-popover{--side-padding:var(--pds-spacing-xl);display:inline-block;font-family:var(--pds-typography-ff-default);position:relative}.pds-notifications-popover__trigger{align-items:center;background-color:transparent;border:none;border-radius:var(--pds-border-radius-button);color:var(--pds-color-foreground-default);cursor:pointer;display:flex;padding:var(--pds-spacing-xs);position:relative}.pds-notifications-popover__trigger:hover{background-color:var(--pds-color-icon-button-standard-background-active)}.pds-notifications-popover__trigger:focus-visible{border-radius:var(--pds-border-radius-container);outline:var(--pds-border-width-outline) solid var(--pds-color-interactive-focus);outline-offset:2px;transition:var(--pds-animation-transition-focus)}.pds-notifications-popover__trigger[aria-expanded=true]{background-color:var(--pds-color-icon-button-standard-background-active)}.pds-notifications-popover__badge{background-color:var(--pds-color-status-info-foreground);border:1px solid var(--pds-color-surface-default-secondary);border-radius:50%;height:.5625rem;position:absolute;right:6px;top:6px;width:.5625rem}.pds-notifications-popover__panel{background-color:var(--pds-color-dropdown-background);border-radius:var(--pds-border-radius-container);box-shadow:var(--pds-elevation-overlay);width:440px}.pds-notifications-popover__panel:focus{outline:none}.pds-notifications-popover__header{align-items:center;border-block-end:1px solid var(--pds-color-border-default);column-gap:var(--pds-spacing-xl);display:flex;justify-content:space-between;padding-block:var(--pds-spacing-m) var(--pds-spacing-s);padding-inline:var(--side-padding)}.pds-notifications-popover__heading{color:var(--pds-color-foreground-default);font-size:var(--pds-typography-size-l);font-weight:var(--pds-typography-fw-semibold);line-height:var(--pds-typography-lh-s)}.pds-notifications-popover__header-actions{align-items:center;column-gap:var(--pds-spacing-s);display:flex;position:relative}.pds-notifications-popover__unread-indicator{background-color:var(--pds-color-status-info-foreground);border-radius:50%;display:block;flex-shrink:0;height:var(--pds-spacing-xs);width:var(--pds-spacing-xs)}.pds-notifications-popover__list{display:flex;flex-direction:column;list-style:none;margin:0;max-height:27rem;overflow-y:auto;padding:0}.pds-notifications-popover__item:not(:first-child){border-top:1px solid var(--pds-color-border-default)}.pds-notifications-popover__item-button{align-items:center;background-color:transparent;border:none;box-sizing:border-box;color:var(--pds-color-dropdown-foreground);column-gap:var(--pds-spacing-l);cursor:pointer;display:flex;font-family:inherit;padding-block:var(--pds-spacing-m);padding-inline:var(--side-padding);position:relative;text-align:left;transition:background-color .2s ease;width:100%}button.pds-notifications-popover__item-button:hover{background-color:var(--pds-color-surface-default-secondary)!important}button.pds-notifications-popover__item-button:focus-visible{outline:var(--pds-border-width-outline) solid var(--pds-color-interactive-focus);outline-offset:-1px}.pds-notifications-popover__item-icon{flex-shrink:0}.pds-notifications-popover__item-content{align-items:flex-start;display:flex;flex-direction:column;padding-inline-end:calc(var(--side-padding)*2);row-gap:var(--pds-spacing-2xs)}.pds-notifications-popover__item-title{font-size:var(--pds-typography-size-s)}.pds-notifications-popover__item-details,.pds-notifications-popover__item-title{font-weight:var(--pds-typography-fw-medium);line-height:var(--pds-typography-lh-s)}.pds-notifications-popover__item-details{color:var(--pds-color-foreground-default);display:flex;font-size:var(--pds-typography-size-xs);gap:var(--pds-spacing-2xs)}.pds-notifications-popover__item-timestamp{color:var(--pds-color-foreground-default-secondary)}.pds-notifications-popover__item-dot{background-color:var(--pds-color-status-info-foreground);border-radius:50%;flex-shrink:0;height:var(--pds-spacing-xs);position:absolute;right:var(--side-padding);width:var(--pds-spacing-xs)}.pds-notifications-popover__empty,.pds-notifications-popover__loading{font-size:var(--pds-typography-size-m);padding-block:var(--pds-spacing-m);padding-inline:var(--side-padding)}.pds-notifications-popover__mobile-footer{border-block-start:1px solid var(--pds-color-border-default);display:none;padding-block:var(--pds-spacing-m);padding-inline:var(--side-padding)}.pds-notifications-popover__toggle-left{align-items:center;column-gap:var(--pds-spacing-m);display:flex;padding-inline-start:.1875rem}[data-pds-mobile] .pds-navbar__mobile .pds-notifications-popover__toggle-left{padding-inline-start:0}.pds-notifications-popover__toggle-icon{align-items:center;color:var(--pds-color-foreground-default);display:flex;flex-shrink:0;position:relative}.pds-notifications-popover__toggle-icon .pds-notifications-popover__badge{position:absolute;right:-2px;top:-2px}.pds-notifications-popover .pds-nav-accordion{display:none}[data-pds-mobile]
2
- .pds-navbar__mobile
3
- .pds-notifications-popover
4
- .pds-nav-accordion{display:block}[data-pds-mobile] .pds-navbar__mobile .pds-notifications-popover__trigger{display:none}[data-pds-mobile] .pds-navbar__mobile .pds-notifications-popover{background-color:var(--pds-color-surface-default);border-block-end:var(--pds-border-width-default) solid var(--pds-color-border-default);left:50%;margin-inline-start:-50vw;position:relative;width:100vw}[data-pds-mobile]
5
- .pds-navbar__mobile
6
- .pds-notifications-popover
7
- .pds-notifications-popover__header{display:none}[data-pds-mobile]
8
- .pds-navbar__mobile
9
- .pds-notifications-popover
10
- .pds-notifications-popover__mobile-footer{display:block}[data-pds-mobile]
11
- .pds-navbar__mobile
12
- .pds-notifications-popover
13
- .pds-notifications-popover__list{max-height:unset}