@sia.soul/sia-react-ui 0.1.103 → 0.1.105

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.
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  FloatingScrollbarProvider,
3
3
  Select
4
- } from "./chunk-KKU35MWK.js";
4
+ } from "./chunk-EYB55TC5.js";
5
5
  import {
6
6
  Icon
7
7
  } from "./chunk-V6CRVCSB.js";
@@ -788,8 +788,8 @@ function Floating({
788
788
  function Tooltip(props) {
789
789
  return /* @__PURE__ */ jsx2(Floating, { ...props, content: props.title });
790
790
  }
791
- function Popover({ title, content, trigger = "click", overlayClassName = "", ...props }) {
792
- return /* @__PURE__ */ jsx2(Floating, { ...props, trigger, role: "dialog", overlayClassName: `sia-popover ${overlayClassName}`.trim(), content: /* @__PURE__ */ jsxs2(Fragment, { children: [
791
+ function Popover({ title, content, contentSize = "default", trigger = "click", overlayClassName = "", ...props }) {
792
+ return /* @__PURE__ */ jsx2(Floating, { ...props, trigger, role: "dialog", overlayClassName: `sia-popover${contentSize === "wide" ? " sia-popover--wide" : ""} ${overlayClassName}`.trim(), content: /* @__PURE__ */ jsxs2(Fragment, { children: [
793
793
  title ? /* @__PURE__ */ jsx2("strong", { className: "sia-popover__title", children: title }) : null,
794
794
  /* @__PURE__ */ jsx2("span", { className: "sia-popover__content", children: content })
795
795
  ] }) });
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Popover,
3
3
  Tooltip
4
- } from "./chunk-KKU35MWK.js";
4
+ } from "./chunk-EYB55TC5.js";
5
5
  import {
6
6
  Dropdown,
7
7
  Icon,
@@ -951,13 +951,15 @@ interface TooltipProps {
951
951
  declare function Tooltip(props: TooltipProps): react.JSX.Element;
952
952
  /** 气泡卡片的属性配置。 */
953
953
  interface PopoverProps extends Omit<TooltipProps, "title"> {
954
+ /** 内容布局预设:default 沿用普通气泡,wide 为表格等宽内容提供 760px 宽度并限制在视口内。@defaultValue "default" */
955
+ contentSize?: "default" | "wide";
954
956
  /** 标题内容,可传入文本或 React 节点。 */
955
957
  title?: ReactNode;
956
958
  /** 需要显示的内容,支持文本或 React 节点。 */
957
959
  content?: ReactNode;
958
960
  }
959
961
  /** 气泡卡片组件。 */
960
- declare function Popover({ title, content, trigger, overlayClassName, ...props }: PopoverProps): react.JSX.Element;
962
+ declare function Popover({ title, content, contentSize, trigger, overlayClassName, ...props }: PopoverProps): react.JSX.Element;
961
963
  /** 时间轴的项目定义。 */
962
964
  type TimelineItem = {
963
965
  /** 子内容;组件嵌套内容或当前节点的子项。 */
@@ -951,13 +951,15 @@ interface TooltipProps {
951
951
  declare function Tooltip(props: TooltipProps): react.JSX.Element;
952
952
  /** 气泡卡片的属性配置。 */
953
953
  interface PopoverProps extends Omit<TooltipProps, "title"> {
954
+ /** 内容布局预设:default 沿用普通气泡,wide 为表格等宽内容提供 760px 宽度并限制在视口内。@defaultValue "default" */
955
+ contentSize?: "default" | "wide";
954
956
  /** 标题内容,可传入文本或 React 节点。 */
955
957
  title?: ReactNode;
956
958
  /** 需要显示的内容,支持文本或 React 节点。 */
957
959
  content?: ReactNode;
958
960
  }
959
961
  /** 气泡卡片组件。 */
960
- declare function Popover({ title, content, trigger, overlayClassName, ...props }: PopoverProps): react.JSX.Element;
962
+ declare function Popover({ title, content, contentSize, trigger, overlayClassName, ...props }: PopoverProps): react.JSX.Element;
961
963
  /** 时间轴的项目定义。 */
962
964
  type TimelineItem = {
963
965
  /** 子内容;组件嵌套内容或当前节点的子项。 */
package/dist/core.css CHANGED
@@ -5188,6 +5188,16 @@ fieldset:disabled .sia-input-number__floating-placeholder {
5188
5188
  min-width: 0;
5189
5189
  width: 0;
5190
5190
  }
5191
+ .sia-query-form__field .sia-space-compact--horizontal:has(> .sia-select:first-child + :is(.sia-picker-range-control, .sia-number-range, .sia-time-range):last-child) > .sia-select {
5192
+ flex: 1 1 0;
5193
+ min-width: 0;
5194
+ width: auto;
5195
+ }
5196
+ .sia-query-form__field .sia-space-compact--horizontal:has(> .sia-select:first-child + :is(.sia-picker-range-control, .sia-number-range, .sia-time-range):last-child) > :last-child {
5197
+ flex: 2 1 0;
5198
+ min-width: 0;
5199
+ width: auto;
5200
+ }
5191
5201
  .sia-query-form__actions {
5192
5202
  display: flex;
5193
5203
  align-items: center;
@@ -5422,6 +5432,125 @@ fieldset:disabled .sia-input-number__floating-placeholder {
5422
5432
  .sia-number-range__clear:hover {
5423
5433
  color: var(--sia-color-text);
5424
5434
  }
5435
+ .sia-auto-sizer {
5436
+ position: relative;
5437
+ width: 100%;
5438
+ height: 100%;
5439
+ min-width: 0;
5440
+ min-height: 0;
5441
+ }
5442
+ .sia-auto-sizer__content {
5443
+ position: absolute;
5444
+ inset: 0;
5445
+ min-width: 0;
5446
+ min-height: 0;
5447
+ }
5448
+ .sia-floating-panel {
5449
+ position: fixed;
5450
+ z-index: 1000;
5451
+ width: 280px;
5452
+ max-width: calc(100vw - 32px);
5453
+ padding: 16px;
5454
+ box-sizing: border-box;
5455
+ border: 1px solid var(--sia-color-border);
5456
+ border-radius: var(--sia-radius, 8px);
5457
+ background: var(--sia-color-surface);
5458
+ color: var(--sia-color-text);
5459
+ box-shadow: 0 6px 20px rgb(0 0 0 / 12%);
5460
+ }
5461
+ .sia-floating-panel--bottomRight {
5462
+ bottom: 24px;
5463
+ right: 16px;
5464
+ }
5465
+ .sia-floating-panel--bottomLeft {
5466
+ bottom: 24px;
5467
+ left: 16px;
5468
+ }
5469
+ .sia-floating-panel--topRight {
5470
+ top: 24px;
5471
+ right: 16px;
5472
+ }
5473
+ .sia-floating-panel--topLeft {
5474
+ top: 24px;
5475
+ left: 16px;
5476
+ }
5477
+ .sia-floating-panel__title {
5478
+ display: block;
5479
+ margin-bottom: 8px;
5480
+ }
5481
+ .sia-sortable-list {
5482
+ display: flex;
5483
+ gap: 16px;
5484
+ overflow: auto;
5485
+ min-width: 0;
5486
+ padding: 4px;
5487
+ }
5488
+ .sia-sortable-list--vertical {
5489
+ flex-direction: column;
5490
+ }
5491
+ .sia-sortable-list__item {
5492
+ position: relative;
5493
+ flex-shrink: 0;
5494
+ min-width: 0;
5495
+ }
5496
+ .sia-sortable-list__item.is-dragging {
5497
+ opacity: .5;
5498
+ }
5499
+ .sia-sortable-list__handle {
5500
+ display: flex;
5501
+ align-items: center;
5502
+ justify-content: center;
5503
+ width: 100%;
5504
+ padding: 6px;
5505
+ border: 0;
5506
+ background: var(--sia-color-fill-secondary);
5507
+ color: var(--sia-color-text-secondary);
5508
+ cursor: grab;
5509
+ }
5510
+ .sia-sortable-list__handle:focus-visible {
5511
+ outline: 2px solid var(--sia-color-primary);
5512
+ outline-offset: -2px;
5513
+ }
5514
+ .sia-sortable-list__handle:disabled {
5515
+ cursor: not-allowed;
5516
+ opacity: .5;
5517
+ }
5518
+ .sia-sortable-list__item.is-drop-before::before,
5519
+ .sia-sortable-list__item.is-drop-after::after {
5520
+ content: "";
5521
+ position: absolute;
5522
+ background: var(--sia-color-primary);
5523
+ pointer-events: none;
5524
+ z-index: 1;
5525
+ }
5526
+ .sia-sortable-list--horizontal .is-drop-before::before {
5527
+ top: 0;
5528
+ bottom: 0;
5529
+ left: -9px;
5530
+ width: 2px;
5531
+ }
5532
+ .sia-sortable-list--horizontal .is-drop-after::after {
5533
+ top: 0;
5534
+ bottom: 0;
5535
+ right: -9px;
5536
+ width: 2px;
5537
+ }
5538
+ .sia-sortable-list--vertical .is-drop-before::before {
5539
+ left: 0;
5540
+ right: 0;
5541
+ top: -9px;
5542
+ height: 2px;
5543
+ }
5544
+ .sia-sortable-list--vertical .is-drop-after::after {
5545
+ left: 0;
5546
+ right: 0;
5547
+ bottom: -9px;
5548
+ height: 2px;
5549
+ }
5550
+ .sia-popover.sia-popover--wide {
5551
+ width: 760px;
5552
+ max-width: calc(100vw - 32px);
5553
+ }
5425
5554
 
5426
5555
  /* src/components-extra.css */
5427
5556
  .sia-flex {
@@ -7844,6 +7973,9 @@ fieldset:disabled .sia-input-number__floating-placeholder {
7844
7973
  gap: 5px;
7845
7974
  min-width: 0;
7846
7975
  }
7976
+ .sia-form-item > .sia-form-item__control:only-child {
7977
+ grid-column: 1 / -1;
7978
+ }
7847
7979
  .sia-form-item__input-wrap {
7848
7980
  position: relative;
7849
7981
  min-width: 0;
package/dist/core.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- export { d as Breadcrumb, e as BreadcrumbItem, f as BreadcrumbProps, h as Card, i as CardAccent, j as CardProps, n as Collapse, o as CollapseItem, p as CollapseKey, q as CollapseProps, x as FilledIconName, y as FloatButton, z as FloatButtonBackTopProps, A as FloatButtonGroupProps, E as FloatButtonProps, G as FloatButtonShape, K as Icon, L as IconName, M as IconProps, N as IconVariant, U as Input, V as InputProps, a0 as MessageConfig, a1 as MessageHandle, a2 as MessageKey, a3 as MessageType, ab as Progress, ac as ProgressProps, ad as ProgressStatus, ag as Result, ah as ResultProps, ai as ResultStatus, aj as Segmented, ak as SegmentedOption, al as SegmentedProps, am as SegmentedValue, at as TabItem, au as Tabs, aw as TabsOrientation, ax as TabsPosition, ay as TabsProps, az as TabsType, aA as Tag, aB as TagProps, aC as TagSize, T as TagStatus, aD as TagVariant, aH as Toolbar, aI as ToolbarItem, aJ as ToolbarProps, aU as Typography, aV as TypographyLinkProps, aW as TypographyProps, aX as TypographyTitleProps, aY as TypographyType, aZ as Upload, a_ as UploadChangeInfo, a$ as UploadDraggerProps, b0 as UploadFile, b1 as UploadFileStatus, b4 as UploadProps, b8 as UploadRequestOptions, bc as message } from './core-BTmyjw4F.cjs';
1
+ export { d as Breadcrumb, e as BreadcrumbItem, f as BreadcrumbProps, h as Card, i as CardAccent, j as CardProps, n as Collapse, o as CollapseItem, p as CollapseKey, q as CollapseProps, x as FilledIconName, y as FloatButton, z as FloatButtonBackTopProps, A as FloatButtonGroupProps, E as FloatButtonProps, G as FloatButtonShape, K as Icon, L as IconName, M as IconProps, N as IconVariant, U as Input, V as InputProps, a0 as MessageConfig, a1 as MessageHandle, a2 as MessageKey, a3 as MessageType, ab as Progress, ac as ProgressProps, ad as ProgressStatus, ag as Result, ah as ResultProps, ai as ResultStatus, aj as Segmented, ak as SegmentedOption, al as SegmentedProps, am as SegmentedValue, at as TabItem, au as Tabs, aw as TabsOrientation, ax as TabsPosition, ay as TabsProps, az as TabsType, aA as Tag, aB as TagProps, aC as TagSize, T as TagStatus, aD as TagVariant, aH as Toolbar, aI as ToolbarItem, aJ as ToolbarProps, aU as Typography, aV as TypographyLinkProps, aW as TypographyProps, aX as TypographyTitleProps, aY as TypographyType, aZ as Upload, a_ as UploadChangeInfo, a$ as UploadDraggerProps, b0 as UploadFile, b1 as UploadFileStatus, b4 as UploadProps, b8 as UploadRequestOptions, bc as message } from './core-DF7gei-P.cjs';
2
2
  export { f as Button, B as ButtonProps, e as ButtonSize, g as ButtonVariant, h as Modal, d as ModalActionResult, M as ModalOpenConfig, i as ModalProps, j as ModalType, a as OverlayApiHandle, k as Select, S as SelectOption, c as SelectProps, m as SelectValue } from './Select-DQpfyK7I.cjs';
3
3
  import 'react';
4
4
  import './shared-Bx4B28Wh.cjs';
package/dist/core.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { d as Breadcrumb, e as BreadcrumbItem, f as BreadcrumbProps, h as Card, i as CardAccent, j as CardProps, n as Collapse, o as CollapseItem, p as CollapseKey, q as CollapseProps, x as FilledIconName, y as FloatButton, z as FloatButtonBackTopProps, A as FloatButtonGroupProps, E as FloatButtonProps, G as FloatButtonShape, K as Icon, L as IconName, M as IconProps, N as IconVariant, U as Input, V as InputProps, a0 as MessageConfig, a1 as MessageHandle, a2 as MessageKey, a3 as MessageType, ab as Progress, ac as ProgressProps, ad as ProgressStatus, ag as Result, ah as ResultProps, ai as ResultStatus, aj as Segmented, ak as SegmentedOption, al as SegmentedProps, am as SegmentedValue, at as TabItem, au as Tabs, aw as TabsOrientation, ax as TabsPosition, ay as TabsProps, az as TabsType, aA as Tag, aB as TagProps, aC as TagSize, T as TagStatus, aD as TagVariant, aH as Toolbar, aI as ToolbarItem, aJ as ToolbarProps, aU as Typography, aV as TypographyLinkProps, aW as TypographyProps, aX as TypographyTitleProps, aY as TypographyType, aZ as Upload, a_ as UploadChangeInfo, a$ as UploadDraggerProps, b0 as UploadFile, b1 as UploadFileStatus, b4 as UploadProps, b8 as UploadRequestOptions, bc as message } from './core-Bn1emNZn.js';
1
+ export { d as Breadcrumb, e as BreadcrumbItem, f as BreadcrumbProps, h as Card, i as CardAccent, j as CardProps, n as Collapse, o as CollapseItem, p as CollapseKey, q as CollapseProps, x as FilledIconName, y as FloatButton, z as FloatButtonBackTopProps, A as FloatButtonGroupProps, E as FloatButtonProps, G as FloatButtonShape, K as Icon, L as IconName, M as IconProps, N as IconVariant, U as Input, V as InputProps, a0 as MessageConfig, a1 as MessageHandle, a2 as MessageKey, a3 as MessageType, ab as Progress, ac as ProgressProps, ad as ProgressStatus, ag as Result, ah as ResultProps, ai as ResultStatus, aj as Segmented, ak as SegmentedOption, al as SegmentedProps, am as SegmentedValue, at as TabItem, au as Tabs, aw as TabsOrientation, ax as TabsPosition, ay as TabsProps, az as TabsType, aA as Tag, aB as TagProps, aC as TagSize, T as TagStatus, aD as TagVariant, aH as Toolbar, aI as ToolbarItem, aJ as ToolbarProps, aU as Typography, aV as TypographyLinkProps, aW as TypographyProps, aX as TypographyTitleProps, aY as TypographyType, aZ as Upload, a_ as UploadChangeInfo, a$ as UploadDraggerProps, b0 as UploadFile, b1 as UploadFileStatus, b4 as UploadProps, b8 as UploadRequestOptions, bc as message } from './core-_1K1jLyH.js';
2
2
  export { f as Button, B as ButtonProps, e as ButtonSize, g as ButtonVariant, h as Modal, d as ModalActionResult, M as ModalOpenConfig, i as ModalProps, j as ModalType, a as OverlayApiHandle, k as Select, S as SelectOption, c as SelectProps, m as SelectValue } from './Select-DmT9pFRW.js';
3
3
  import 'react';
4
4
  import './shared-Bx4B28Wh.js';
package/dist/core.js CHANGED
@@ -11,10 +11,10 @@ import {
11
11
  Typography,
12
12
  Upload,
13
13
  message
14
- } from "./chunk-6KWMZ7JJ.js";
14
+ } from "./chunk-X4OLHWC3.js";
15
15
  import {
16
16
  Select
17
- } from "./chunk-KKU35MWK.js";
17
+ } from "./chunk-EYB55TC5.js";
18
18
  import {
19
19
  Icon,
20
20
  Input,