@qq1948037137/adminsmart-ui 0.1.30 → 0.1.31

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/README.md CHANGED
@@ -51,7 +51,7 @@ function Example() {
51
51
 
52
52
  `Pagination`、`Table`、`DataTable` 和显式启用分页的 `List` 默认显示 `共 N 条`,数量来自 Ant 的本地数据总数或业务传入的 `total`,不会把当前页行数当作完整数量。原生 `showTotal={(total, range) => ...}` 可自定义总数文案,显式 `showTotal={undefined}` 可隐藏;表格和列表仍可通过 `pagination={false}` 关闭分页。页码、每页条数、回调、ref 和原生公开类型继续保留,列表未配置分页时不会额外开启分页。
53
53
 
54
- 用 `ReportErrorProvider` 在应用入口绑定问题上报行为。`OperationToolbar` 将「问题上报」放在新增、导出等左侧业务操作之后,右侧的 `TableControls` 依次提供搜索显隐、刷新和选择列。`SearchPanel.tools/trailingTools` 和 `CrudWorkspace.actions/controls` 会使用同一个操作栏。没有列表工具栏的页面可使用 `ErrorReportButton`。宿主负责采集范围、脱敏、请求和结果反馈。
54
+ 用 `ReportErrorProvider` 在应用入口绑定问题上报行为。`OperationToolbar` 将「问题上报」放在新增、导出等左侧业务操作之后,右侧的 `TableControls` 依次提供搜索显隐、刷新和选择列。`SearchPanel.tools/trailingTools` 和 `CrudWorkspace.actions/controls` 会使用同一个操作栏。没有列表工具栏的页面可使用 `ErrorReportButton`。上报中通过文字展示进度并阻止重复提交,`description` 供辅助技术读取。宿主负责采集范围、脱敏、请求和结果反馈。
55
55
 
56
56
  在 `WorkspaceLayout contentMode="table"` 的内容区嵌入 `CrudWorkspace`,可使用独立的筛选、操作栏、反馈与页脚插槽,`DataTable` 自动填满剩余区域。结果超出高度时在表体内滚动,分页仍保持可见。文档站的「CrudWorkspace 标准 CRUD 工作区」展示同一布局中的搜索、刷新、显隐列、新建、编辑和删除。
57
57
 
package/dist/index.cjs CHANGED
@@ -1295,21 +1295,20 @@ var SessionReplay = (0, import_react6.forwardRef)(function SessionReplay2({ even
1295
1295
  });
1296
1296
 
1297
1297
  // src/composites/SearchPanel.tsx
1298
- var import_icons4 = require("@ant-design/icons");
1298
+ var import_icons3 = require("@ant-design/icons");
1299
1299
  var import_react9 = require("react");
1300
1300
 
1301
1301
  // src/composites/OperationToolbar.tsx
1302
1302
  var import_react8 = require("react");
1303
1303
 
1304
1304
  // src/composites/ErrorReportButton.tsx
1305
- var import_icons3 = require("@ant-design/icons");
1306
1305
  var import_react7 = require("react");
1307
1306
  var import_jsx_runtime5 = require("react/jsx-runtime");
1308
1307
  function ErrorReportButton({
1309
1308
  onReport,
1310
1309
  disabled = false,
1311
1310
  onReportFailure,
1312
- description = "\u95EE\u9898\u4E0A\u62A5"
1311
+ description
1313
1312
  }) {
1314
1313
  const pending = (0, import_react7.useRef)(false);
1315
1314
  const [reporting, setReporting] = (0, import_react7.useState)(false);
@@ -1326,17 +1325,17 @@ function ErrorReportButton({
1326
1325
  setReporting(false);
1327
1326
  }
1328
1327
  }
1329
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Tooltip, { title: description, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1328
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1330
1329
  Button,
1331
1330
  {
1332
1331
  "data-adminsmart-error-report": "true",
1333
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_icons3.BugOutlined, { "aria-hidden": "true" }),
1334
- disabled,
1335
- loading: reporting,
1332
+ "aria-description": description,
1333
+ "aria-busy": reporting || void 0,
1334
+ disabled: disabled || reporting,
1336
1335
  onClick: report,
1337
- children: "\u95EE\u9898\u4E0A\u62A5"
1336
+ children: reporting ? "\u4E0A\u62A5\u4E2D\u2026" : "\u95EE\u9898\u4E0A\u62A5"
1338
1337
  }
1339
- ) });
1338
+ );
1340
1339
  }
1341
1340
 
1342
1341
  // src/composites/OperationToolbar.tsx
@@ -1424,7 +1423,7 @@ var SearchPanel = (0, import_react9.forwardRef)(function SearchPanel2({ fields,
1424
1423
  Button,
1425
1424
  {
1426
1425
  type: "link",
1427
- icon: expanded ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_icons4.UpOutlined, {}) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_icons4.DownOutlined, {}),
1426
+ icon: expanded ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_icons3.UpOutlined, {}) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_icons3.DownOutlined, {}),
1428
1427
  "aria-expanded": expanded,
1429
1428
  onClick: () => setExpanded((value) => !value),
1430
1429
  children: expanded ? "\u6536\u8D77\u7B5B\u9009" : "\u5C55\u5F00\u7B5B\u9009"
@@ -1438,7 +1437,7 @@ var SearchPanel = (0, import_react9.forwardRef)(function SearchPanel2({ fields,
1438
1437
  });
1439
1438
 
1440
1439
  // src/composites/TableControls.tsx
1441
- var import_icons5 = require("@ant-design/icons");
1440
+ var import_icons4 = require("@ant-design/icons");
1442
1441
  var import_react10 = require("react");
1443
1442
  var import_jsx_runtime8 = require("react/jsx-runtime");
1444
1443
  function TableControls({
@@ -1487,7 +1486,7 @@ function TableControls({
1487
1486
  /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Tooltip, { title: searchLabel, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1488
1487
  Button,
1489
1488
  {
1490
- icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons5.SearchOutlined, { "aria-hidden": "true" }),
1489
+ icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons4.SearchOutlined, { "aria-hidden": "true" }),
1491
1490
  "aria-label": searchLabel,
1492
1491
  "aria-pressed": searchVisible,
1493
1492
  "data-adminsmart-table-tool": "true",
@@ -1498,7 +1497,7 @@ function TableControls({
1498
1497
  /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Tooltip, { title: "\u5237\u65B0\u5217\u8868", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1499
1498
  Button,
1500
1499
  {
1501
- icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons5.ReloadOutlined, { "aria-hidden": "true" }),
1500
+ icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons4.ReloadOutlined, { "aria-hidden": "true" }),
1502
1501
  "aria-label": "\u5237\u65B0\u5217\u8868",
1503
1502
  "data-adminsmart-table-tool": "true",
1504
1503
  loading: refreshing,
@@ -1542,7 +1541,7 @@ function TableControls({
1542
1541
  Button,
1543
1542
  {
1544
1543
  ref: triggerRef,
1545
- icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons5.SettingOutlined, { "aria-hidden": "true" }),
1544
+ icon: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_icons4.SettingOutlined, { "aria-hidden": "true" }),
1546
1545
  "aria-label": "\u8BBE\u7F6E\u663E\u793A\u5217",
1547
1546
  "data-adminsmart-table-tool": "true",
1548
1547
  "aria-haspopup": "dialog",
@@ -1774,7 +1773,7 @@ function EllipsisText({
1774
1773
  }
1775
1774
 
1776
1775
  // src/composites/RowActions.tsx
1777
- var import_icons6 = require("@ant-design/icons");
1776
+ var import_icons5 = require("@ant-design/icons");
1778
1777
  var import_react13 = require("react");
1779
1778
  var import_jsx_runtime14 = require("react/jsx-runtime");
1780
1779
  function collectButtons(children) {
@@ -1826,7 +1825,7 @@ function RowActions({ children, maxVisible = 2, moreLabel = "\u66F4\u591A\u64CD\
1826
1825
  {
1827
1826
  type: "text",
1828
1827
  size: "small",
1829
- icon: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons6.EllipsisOutlined, {}),
1828
+ icon: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons5.EllipsisOutlined, {}),
1830
1829
  "aria-label": moreLabel,
1831
1830
  "aria-haspopup": "menu",
1832
1831
  "data-adminsmart-row-more": "true",