myoperator-ui 0.0.227 → 0.0.229

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 (2) hide show
  1. package/dist/index.js +16 -31
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -7968,7 +7968,7 @@ export interface PageHeaderProps
7968
7968
  actions?: React.ReactNode;
7969
7969
  /** Show bottom border (default: true) */
7970
7970
  showBorder?: boolean;
7971
- /** Layout mode: 'horizontal' (single row), 'vertical' (stacked), 'responsive' (auto based on screen size, default) */
7971
+ /** Layout mode: 'horizontal' (row on sm+, stacked on narrow), 'vertical' (stacked), 'responsive' (same as horizontal, default) */
7972
7972
  layout?: "horizontal" | "vertical" | "responsive";
7973
7973
  /** Max actions to show on mobile before overflow (default: 2) */
7974
7974
  mobileOverflowLimit?: number;
@@ -8048,13 +8048,13 @@ const PageHeader = React.forwardRef(
8048
8048
 
8049
8049
  // Layout classes based on prop
8050
8050
  const layoutClasses = {
8051
- horizontal: "flex-row items-center",
8051
+ horizontal: "flex-col sm:flex-row sm:items-center",
8052
8052
  vertical: "flex-col",
8053
8053
  responsive: "flex-col sm:flex-row sm:items-center",
8054
8054
  };
8055
8055
 
8056
8056
  const heightClasses = {
8057
- horizontal: "h-[76px]",
8057
+ horizontal: "min-h-[76px] py-4 lg:py-0 lg:h-[76px]",
8058
8058
  vertical: "min-h-[76px] py-4",
8059
8059
  responsive: "min-h-[76px] py-4 lg:py-0 lg:h-[76px]",
8060
8060
  };
@@ -8117,27 +8117,14 @@ const PageHeader = React.forwardRef(
8117
8117
  );
8118
8118
  };
8119
8119
 
8120
- // For horizontal layout, always show all actions inline
8121
- const renderHorizontalActions = () => (
8122
- <div className="flex items-center gap-2 ml-4">
8123
- {actionsArray.map((action, index) => (
8124
- <React.Fragment key={index}>{action}</React.Fragment>
8125
- ))}
8126
- </div>
8127
- );
8128
-
8129
8120
  const renderActions = () => {
8130
8121
  if (!actions) return null;
8131
8122
 
8132
- if (layout === "horizontal") {
8133
- return renderHorizontalActions();
8134
- }
8135
-
8136
8123
  if (layout === "vertical") {
8137
8124
  return renderExpandableActions("mt-3");
8138
8125
  }
8139
8126
 
8140
- // Responsive: render both, CSS handles visibility
8127
+ // horizontal + responsive: stack actions below title on small screens
8141
8128
  return (
8142
8129
  <>
8143
8130
  {renderDesktopActions()}
@@ -8161,7 +8148,12 @@ const PageHeader = React.forwardRef(
8161
8148
  {...props}
8162
8149
  >
8163
8150
  {/* Top Row: Icon/Back + Title + Description */}
8164
- <div className="flex items-start sm:items-center flex-1 min-w-0">
8151
+ <div
8152
+ className={cn(
8153
+ "flex flex-1 min-w-0",
8154
+ description ? "items-start sm:items-center" : "items-center"
8155
+ )}
8156
+ >
8165
8157
  {/* Left Section: Icon or Back Button */}
8166
8158
  {leftElement && (
8167
8159
  <div className="flex-shrink-0 mr-4">{leftElement}</div>
@@ -8169,8 +8161,8 @@ const PageHeader = React.forwardRef(
8169
8161
 
8170
8162
  {/* Content Section: Title + Description */}
8171
8163
  <div className="flex-1 min-w-0">
8172
- <div className="flex items-center gap-2">
8173
- <h1 className="m-0 text-lg font-semibold text-semantic-text-primary truncate">
8164
+ <div className="flex h-auto items-center gap-2 sm:min-h-10">
8165
+ <h1 className="m-0 text-lg font-semibold leading-none text-semantic-text-primary truncate">
8174
8166
  {title}
8175
8167
  </h1>
8176
8168
  {badge && (
@@ -14633,7 +14625,8 @@ export const CreateBotModal = React.forwardRef(
14633
14625
  ref={ref}
14634
14626
  size="sm"
14635
14627
  className={cn(
14636
- "mx-3 max-h-[90vh] overflow-y-auto w-[calc(100%-1.5rem)] sm:mx-auto sm:w-full",
14628
+ // Do not use horizontal margin here \u2014 it breaks left-1/2 + -translate-x-1/2 centering on DialogContent.
14629
+ "max-h-[90vh] overflow-y-auto w-[min(100%,calc(100vw-1.5rem))]",
14637
14630
  className
14638
14631
  )}
14639
14632
  >
@@ -15568,14 +15561,6 @@ function useFakeProgress() {
15568
15561
  return { start, cancel, cancelAll };
15569
15562
  }
15570
15563
 
15571
- function getTimeRemaining(progress: number) {
15572
- const steps = Math.ceil((100 - progress) / 15);
15573
- const secs = steps * 3;
15574
- return secs > 60
15575
- ? \`\${Math.ceil(secs / 60)} minutes remaining\`
15576
- : \`\${secs} seconds remaining\`;
15577
- }
15578
-
15579
15564
  const FileUploadModal = React.forwardRef(
15580
15565
  (
15581
15566
  {
@@ -15821,8 +15806,7 @@ const FileUploadModal = React.forwardRef(
15821
15806
  </p>
15822
15807
  {item.status === "uploading" && (
15823
15808
  <p className="m-0 text-xs text-semantic-text-muted tracking-[0.048px]">
15824
- {item.progress}%&nbsp;&bull;&nbsp;
15825
- {getTimeRemaining(item.progress)}
15809
+ {item.progress}%
15826
15810
  </p>
15827
15811
  )}
15828
15812
  {item.status === "error" && (
@@ -20461,6 +20445,7 @@ const BotIdentityCard = React.forwardRef(
20461
20445
 
20462
20446
  <Field
20463
20447
  label="Primary Role"
20448
+ helperText="Defines what the bot does. Choose from the list or type a custom role."
20464
20449
  characterCount={{
20465
20450
  current: (data.primaryRole ?? "").length,
20466
20451
  max: PRIMARY_ROLE_MAX_LENGTH,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "myoperator-ui",
3
- "version": "0.0.227",
3
+ "version": "0.0.229",
4
4
  "description": "CLI for adding myOperator UI components to your project",
5
5
  "type": "module",
6
6
  "exports": "./dist/index.js",