@next-bricks/basic-bricks 1.179.6 → 1.179.9

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/stories.json CHANGED
@@ -1121,7 +1121,7 @@
1121
1121
  "events": [
1122
1122
  {
1123
1123
  "type": "general.button.click",
1124
- "detail": "`any`",
1124
+ "detail": "`Record<string, any>`",
1125
1125
  "description": "按钮被点击时触发, detail 为 dataSource 数据"
1126
1126
  }
1127
1127
  ],
@@ -1139,8 +1139,8 @@
1139
1139
  "type": "MenuIcon",
1140
1140
  "required": "false",
1141
1141
  "default": "-",
1142
- "description": "按钮 icon,支持[icon 图标库](developers/icon),可直接复制图标图标的配置(antd、fa easyops 三种库都支持),也可只取 icon 字段的值(仅支持 antd 库)。配置{ \"lib\": \"antd\", \"icon\": \"edit\" }与 \"edit\"等价",
1143
- "group": "basic"
1142
+ "description": "按钮 icon,支持的 [icon 图标库](developers/icon) [MenuIcon配置](/next-docs/docs/api-reference/brick-types.menuicon#menuicon-interface),另外如果是 antd 图标库可以直接引用图标名称配置 { \"lib\": \"antd\", \"icon\": \"edit\" }与 \"edit\"等价",
1143
+ "group": "ui"
1144
1144
  },
1145
1145
  {
1146
1146
  "name": "buttonUrl",
@@ -1163,14 +1163,14 @@
1163
1163
  "type": "string",
1164
1164
  "required": "false",
1165
1165
  "default": "-",
1166
- "description": "跳转的 target,例如可以设置为\"\\_blank\"",
1166
+ "description": "跳转的 target,例如可以设置为\"_blank\"",
1167
1167
  "group": "basic"
1168
1168
  },
1169
1169
  {
1170
1170
  "name": "dataSource",
1171
- "type": "any",
1171
+ "type": "Record<string, any>",
1172
1172
  "required": "false",
1173
- "default": "`{}`",
1173
+ "default": "{}",
1174
1174
  "description": "替代之前 detail 属性,用法相同。暂存的数据在事件传出时使用",
1175
1175
  "group": "basic"
1176
1176
  },
@@ -1178,7 +1178,7 @@
1178
1178
  "name": "disabled",
1179
1179
  "type": "boolean",
1180
1180
  "required": "false",
1181
- "default": "`false`",
1181
+ "default": "false",
1182
1182
  "description": "是否禁用按钮",
1183
1183
  "group": "basic"
1184
1184
  },
@@ -1186,8 +1186,9 @@
1186
1186
  "name": "loading",
1187
1187
  "type": "boolean",
1188
1188
  "required": "false",
1189
- "default": "`false`",
1190
- "description": "按钮加载动画"
1189
+ "default": "false",
1190
+ "description": "按钮加载动画",
1191
+ "group": "ui"
1191
1192
  },
1192
1193
  {
1193
1194
  "name": "buttonType",
@@ -1195,15 +1196,15 @@
1195
1196
  "required": "false",
1196
1197
  "default": "-",
1197
1198
  "description": "按钮类型 ButtonType(`\"link\" | \"default\" | \"primary\" | \"ghost\" | \"dashed\" | \"danger\" | \"icon\"|\"text\"`)",
1198
- "group": "basic"
1199
+ "group": "ui"
1199
1200
  },
1200
1201
  {
1201
1202
  "name": "buttonDanger",
1202
1203
  "type": "boolean",
1203
1204
  "required": "false",
1204
- "default": "`false`",
1205
+ "default": "false",
1205
1206
  "description": "设置危险按钮",
1206
- "group": "basic"
1207
+ "group": "ui"
1207
1208
  },
1208
1209
  {
1209
1210
  "name": "buttonShape",
@@ -1211,7 +1212,7 @@
1211
1212
  "required": "false",
1212
1213
  "default": "-",
1213
1214
  "description": "按钮形状,支持圆形、椭圆形,不设置为默认方形",
1214
- "group": "basic"
1215
+ "group": "ui"
1215
1216
  },
1216
1217
  {
1217
1218
  "name": "buttonSize",
@@ -1219,7 +1220,7 @@
1219
1220
  "required": "false",
1220
1221
  "default": "-",
1221
1222
  "description": "按钮大小,支持大、小,不设置为默认中",
1222
- "group": "basic"
1223
+ "group": "ui"
1223
1224
  },
1224
1225
  {
1225
1226
  "name": "tooltip",
@@ -1249,17 +1250,17 @@
1249
1250
  "name": "fadedText",
1250
1251
  "type": "boolean",
1251
1252
  "required": "false",
1252
- "default": "`false`",
1253
+ "default": "false",
1253
1254
  "description": "淡化按钮文字,按钮类型为 text 时可以设置。默认 `false` 文字按钮颜色和平台的字体颜色一样,在一些希望弱化文字颜色的场景下可以设置为 `true`。",
1254
- "group": "advanced"
1255
+ "group": "ui"
1255
1256
  },
1256
1257
  {
1257
1258
  "name": "disableAfterClick",
1258
1259
  "type": "boolean",
1259
1260
  "required": "false",
1260
- "default": "`false`",
1261
+ "default": "false",
1261
1262
  "description": "点击按钮后自动禁用",
1262
- "group": "advanced"
1263
+ "group": "basic"
1263
1264
  },
1264
1265
  {
1265
1266
  "name": "buttonProps",
@@ -1267,7 +1268,15 @@
1267
1268
  "required": "-",
1268
1269
  "default": "-",
1269
1270
  "description": "完全透传给 antd 的 Button 属性",
1270
- "group": "advanced"
1271
+ "group": "basic"
1272
+ },
1273
+ {
1274
+ "name": "buttonStyle",
1275
+ "type": "React.CSSProperties",
1276
+ "required": "-",
1277
+ "default": "-",
1278
+ "description": "适用于按钮某些场景下,需要自定义一些样式",
1279
+ "group": "ui"
1271
1280
  },
1272
1281
  {
1273
1282
  "name": "detail",
@@ -1276,15 +1285,7 @@
1276
1285
  "default": "{}",
1277
1286
  "deprecated": true,
1278
1287
  "description": "[已废弃]按钮点击事件传出的内容。当用于列表类构件,例如 `brick-table` 中,可通过传入传入 `detail` 来识别不通的行进行操作处理。",
1279
- "group": "advanced"
1280
- },
1281
- {
1282
- "name": "buttonStyle",
1283
- "type": "React.CSSProperties",
1284
- "required": "-",
1285
- "default": "-",
1286
- "description": "适用于按钮某些场景下,需要自定义一些样式",
1287
- "group": "advanced"
1288
+ "group": "basic"
1288
1289
  }
1289
1290
  ],
1290
1291
  "interface": [
@@ -1549,7 +1550,7 @@
1549
1550
  {
1550
1551
  "description": {
1551
1552
  "title": "使用footer插槽",
1552
- "message": "适用于多表单使用,具体场景请参考http://192.168.100.162/next/resource-events/alert-config/inhibition-rule/create"
1553
+ "message": "适用于多表单使用,具体场景请参考 [#1](http://192.168.100.162/next/resource-events/alert-config/inhibition-rule/create)"
1553
1554
  },
1554
1555
  "brick": "forms.general-form",
1555
1556
  "properties": {
@@ -1769,7 +1770,16 @@
1769
1770
  "change": "新增属性 `fillVertical`"
1770
1771
  }
1771
1772
  ],
1772
- "memo": "```typescript\n export interface OperationButton {\n // to listen for\n id: string;\n eventName: string;\n configProps: ButtonProps;\n text?: string;\n needData?: boolean;\n }\n ```",
1773
+ "groupI18N": {
1774
+ "basic": {
1775
+ "en": "Basic",
1776
+ "zh": "常用"
1777
+ },
1778
+ "ui": {
1779
+ "en": "UI",
1780
+ "zh": "外观"
1781
+ }
1782
+ },
1773
1783
  "properties": [
1774
1784
  {
1775
1785
  "name": "cardTitle",
@@ -1785,7 +1795,7 @@
1785
1795
  "required": "false",
1786
1796
  "default": "false",
1787
1797
  "description": "设置该属性后,设置卡片高度为 100%,卡片高度会自动撑满父容器",
1788
- "group": "basic"
1798
+ "group": "ui"
1789
1799
  },
1790
1800
  {
1791
1801
  "name": "verticalCenter",
@@ -1793,7 +1803,7 @@
1793
1803
  "required": "false",
1794
1804
  "default": "false",
1795
1805
  "description": "设置该属性后,卡片内容区的元素自动垂直居中",
1796
- "group": "basic"
1806
+ "group": "ui"
1797
1807
  },
1798
1808
  {
1799
1809
  "name": "hasExtraSlot",
@@ -1806,7 +1816,7 @@
1806
1816
  {
1807
1817
  "name": "hasFooter",
1808
1818
  "type": "boolean",
1809
- "group": "advanced"
1819
+ "group": "basic"
1810
1820
  },
1811
1821
  {
1812
1822
  "name": "isFixedFooter",
@@ -1814,24 +1824,68 @@
1814
1824
  "required": "false",
1815
1825
  "default": "true",
1816
1826
  "description": "footer滚动到窗口外时,是否需要将footer固定在窗口底部",
1817
- "group": "advanced"
1827
+ "group": "basic"
1818
1828
  },
1819
1829
  {
1820
- "name": "configProps",
1821
- "type": "map",
1830
+ "name": "operationButtons",
1831
+ "type": "OperationButton[]",
1822
1832
  "required": "false",
1823
1833
  "default": "-",
1824
- "description": "完全透传给 antd 的 Card 属性,详见:[https://ant.design/components/card-cn/#Card](https://ant.design/components/card-cn/#Card)"
1834
+ "description": "右上角的操作按钮列表,可自定义指定该按钮的名字,按钮点击后发出的事件等"
1825
1835
  },
1826
1836
  {
1827
- "name": "operationButtons",
1828
- "type": "OperationButton[]",
1837
+ "name": "configProps",
1838
+ "type": "map",
1829
1839
  "required": "false",
1830
1840
  "default": "-",
1831
- "description": "右上角的操作按钮列表,可自定义指定该按钮的名字,并配置该按钮点击后发出的事件,在 storyboard 去监听该事件传给目标"
1841
+ "description": "完全透传给 antd 的 Card 属性,详见:[Card](https://ant.design/components/card-cn/#Card)"
1832
1842
  }
1833
1843
  ],
1834
- "interface": []
1844
+ "interface": [
1845
+ {
1846
+ "name": "OperationButton",
1847
+ "typeParameter": null,
1848
+ "kind": "interface",
1849
+ "children": [
1850
+ {
1851
+ "name": "configProps",
1852
+ "type": "ButtonProps & object",
1853
+ "required": true,
1854
+ "description": ""
1855
+ },
1856
+ {
1857
+ "name": "eventName",
1858
+ "type": "string",
1859
+ "required": true,
1860
+ "description": ""
1861
+ },
1862
+ {
1863
+ "name": "id",
1864
+ "type": "string",
1865
+ "required": true,
1866
+ "description": ""
1867
+ },
1868
+ {
1869
+ "name": "needData",
1870
+ "type": "boolean",
1871
+ "required": false,
1872
+ "description": ""
1873
+ },
1874
+ {
1875
+ "name": "text",
1876
+ "type": "string",
1877
+ "required": false,
1878
+ "description": ""
1879
+ },
1880
+ {
1881
+ "name": "tooltip",
1882
+ "type": "string",
1883
+ "required": false,
1884
+ "description": ""
1885
+ }
1886
+ ]
1887
+ }
1888
+ ]
1835
1889
  }
1836
1890
  },
1837
1891
  {
@@ -4555,7 +4609,7 @@
4555
4609
  "author": "steve",
4556
4610
  "slots": null,
4557
4611
  "history": null,
4558
- "memo": "### interface\n```typescript\n interface ResponsiveSettings {\n large?: GridSettings;\n medium?: GridSettings;\n small?: GridSettings;\n xSmall?: GridSettings;\n }\n\n interface GridSettings {\n columns?: number;\n rows?: number;\n columnSpan?: number;\n rowSpan?: number;\n }\n```\n### 响应式布局说明\n\nBootstrap 等 UI 框架是移动优先的设计,它们的响应式为默认匹配小屏幕,并由小到大适配。而 EasyOps 平台以 PC 优先,并由大到小适配。这里我们针对常见桌面显示器大小,分为以下五档(屏幕宽度):\n\n- `xSmall`:<= 1024px (老式投影仪)\n- `small`:<= 1280px (13 寸笔记本)\n- `medium`:<= 1600px (中等显示器)\n- `large`:<= 1920px (大号显示器)\n- 其它:超大显示器\n\n例如以下设置:\n\n```json\n{\n \"columns\": 3,\n \"responsive\": {\n \"medium\": {\n \"columns\": 2\n },\n \"small\": {\n \"columns\": 1\n }\n }\n}\n```\n\n在 `> 1600px` 的屏幕上时将显示为三列,`<= 1600px && > 1280px` 时显示两列,更小的屏幕显示为一列。",
4612
+ "memo": "### 响应式布局说明\n\nBootstrap 等 UI 框架是移动优先的设计,它们的响应式为默认匹配小屏幕,并由小到大适配。而 EasyOps 平台以 PC 优先,并由大到小适配。这里我们针对常见桌面显示器大小,分为以下五档(屏幕宽度):\n\n- `xSmall`:<= 1024px (老式投影仪)\n- `small`:<= 1280px (13 寸笔记本)\n- `medium`:<= 1600px (中等显示器)\n- `large`:<= 1920px (大号显示器)\n- 其它:超大显示器\n\n例如以下设置:\n\n```json\n{\n \"columns\": 3,\n \"responsive\": {\n \"medium\": {\n \"columns\": 2\n },\n \"small\": {\n \"columns\": 1\n }\n }\n}\n```\n\n在 `> 1600px` 的屏幕上时将显示为三列,`<= 1600px && > 1280px` 时显示两列,更小的屏幕显示为一列。",
4559
4613
  "properties": [
4560
4614
  {
4561
4615
  "name": "columns",
@@ -4594,7 +4648,76 @@
4594
4648
  "description": "响应式布局设置"
4595
4649
  }
4596
4650
  ],
4597
- "interface": []
4651
+ "interface": [
4652
+ {
4653
+ "name": "ResponsiveSettings",
4654
+ "typeParameter": null,
4655
+ "kind": "interface",
4656
+ "children": [
4657
+ {
4658
+ "name": "large",
4659
+ "type": "GridSettings",
4660
+ "required": false,
4661
+ "description": ""
4662
+ },
4663
+ {
4664
+ "name": "medium",
4665
+ "type": "GridSettings",
4666
+ "required": false,
4667
+ "description": ""
4668
+ },
4669
+ {
4670
+ "name": "small",
4671
+ "type": "GridSettings",
4672
+ "required": false,
4673
+ "description": ""
4674
+ },
4675
+ {
4676
+ "name": "xSmall",
4677
+ "type": "GridSettings",
4678
+ "required": false,
4679
+ "description": ""
4680
+ }
4681
+ ]
4682
+ },
4683
+ {
4684
+ "name": "GridSettings",
4685
+ "typeParameter": null,
4686
+ "kind": "interface",
4687
+ "children": [
4688
+ {
4689
+ "name": "columnSpan",
4690
+ "type": "number",
4691
+ "required": false,
4692
+ "description": ""
4693
+ },
4694
+ {
4695
+ "name": "columns",
4696
+ "type": "number",
4697
+ "required": false,
4698
+ "description": ""
4699
+ },
4700
+ {
4701
+ "name": "rowSpan",
4702
+ "type": "number",
4703
+ "required": false,
4704
+ "description": ""
4705
+ },
4706
+ {
4707
+ "name": "rows",
4708
+ "type": "number",
4709
+ "required": false,
4710
+ "description": ""
4711
+ },
4712
+ {
4713
+ "name": "templateColumns",
4714
+ "type": "string",
4715
+ "required": false,
4716
+ "description": ""
4717
+ }
4718
+ ]
4719
+ }
4720
+ ]
4598
4721
  }
4599
4722
  },
4600
4723
  {
@@ -5328,6 +5451,16 @@
5328
5451
  "change": "新增 bannerPageTitle、bannerStyle 属性,banner、bannerTitleBar、bannerToolbar 插槽"
5329
5452
  }
5330
5453
  ],
5454
+ "groupI18N": {
5455
+ "basic": {
5456
+ "zh": "常用",
5457
+ "en": "Basic"
5458
+ },
5459
+ "ui": {
5460
+ "zh": "外观",
5461
+ "en": "UI"
5462
+ }
5463
+ },
5331
5464
  "memo": "",
5332
5465
  "properties": [
5333
5466
  {
@@ -5338,86 +5471,56 @@
5338
5471
  "description": "设置标题。如果要使用复杂的标题构件,请使用插槽 `titleBar`",
5339
5472
  "group": "basic"
5340
5473
  },
5474
+ {
5475
+ "name": "bannerPageTitle",
5476
+ "type": "string",
5477
+ "required": "-",
5478
+ "default": "-",
5479
+ "description": "设置 banner 标题。如果要使用复杂的标题构件,请使用插槽 `bannerTitleBar`",
5480
+ "group": "basic"
5481
+ },
5341
5482
  {
5342
5483
  "name": "overflowXAuto",
5343
5484
  "type": "boolean",
5344
5485
  "required": "-",
5345
- "default": "`false`",
5486
+ "default": "false",
5346
5487
  "description": "内容区是否需要设置`overflow-x: auto`",
5347
- "group": "basic"
5488
+ "group": "ui"
5348
5489
  },
5349
5490
  {
5350
5491
  "name": "noGap",
5351
5492
  "type": "boolean",
5352
5493
  "required": "-",
5353
- "default": "`false`",
5494
+ "default": "false",
5354
5495
  "description": "内容区默认为 grid 布局且有默认的 gap,设为 `true` 则使之没有 gap。",
5355
- "group": "basic"
5496
+ "group": "ui"
5356
5497
  },
5357
5498
  {
5358
5499
  "name": "dashboardMode",
5359
5500
  "type": "boolean",
5360
- "default": "`false`",
5501
+ "default": "false",
5361
5502
  "description": "是否启用大屏模式。",
5362
- "group": "basic"
5503
+ "group": "ui"
5504
+ },
5505
+ {
5506
+ "name": "pageTitleScale",
5507
+ "type": "number",
5508
+ "description": "标题栏大小比例,默认为 1,仅用于暗黑大屏模式。",
5509
+ "group": "ui"
5363
5510
  },
5364
5511
  {
5365
5512
  "name": "hideToolbar",
5366
5513
  "type": "boolean",
5367
- "default": "`false`",
5514
+ "default": "false",
5368
5515
  "description": "是否隐藏工具栏(常用语大屏模式)。",
5369
- "group": "basic"
5370
- },
5371
- {
5372
- "name": "bannerPageTitle",
5373
- "type": "string",
5374
- "required": "-",
5375
- "default": "-",
5376
- "description": "设置 banner 标题。如果要使用复杂的标题构件,请使用插槽 `bannerTitleBar`",
5377
- "group": "advanced"
5516
+ "group": "ui"
5378
5517
  },
5379
5518
  {
5380
5519
  "name": "bannerStyle",
5381
5520
  "type": "CSSProperties",
5382
5521
  "default": "-",
5383
5522
  "description": "banner 的样式",
5384
- "group": "advanced"
5385
- },
5386
- {
5387
- "name": "hasSubMenu",
5388
- "type": "boolean",
5389
- "group": "advanced"
5390
- },
5391
- {
5392
- "name": "hasTitleBar",
5393
- "type": "boolean",
5394
- "group": "advanced"
5395
- },
5396
- {
5397
- "name": "hasToolbar",
5398
- "type": "boolean",
5399
- "group": "advanced"
5400
- },
5401
- {
5402
- "name": "hasBanner",
5403
- "type": "boolean",
5404
- "group": "advanced"
5405
- },
5406
- {
5407
- "name": "hasBannerTitleBar",
5408
- "type": "boolean",
5409
- "group": "advanced"
5410
- },
5411
- {
5412
- "name": "hasBannerToolbar",
5413
- "type": "boolean",
5414
- "group": "advanced"
5415
- },
5416
- {
5417
- "name": "pageTitleScale",
5418
- "type": "number",
5419
- "description": "标题栏大小比例,默认为 1,仅用于暗黑大屏模式。",
5420
- "group": "advanced"
5523
+ "group": "ui"
5421
5524
  }
5422
5525
  ],
5423
5526
  "interface": []
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/basic-bricks",
3
- "version": "1.179.6",
3
+ "version": "1.179.9",
4
4
  "description": "> TODO: description",
5
5
  "homepage": "https://github.com/easyops-cn/next-basics/tree/master/bricks/basic-bricks",
6
6
  "license": "GPL-3.0",
@@ -39,5 +39,5 @@
39
39
  "immutability-helper": "^3.1.1"
40
40
  },
41
41
  "sideEffects": true,
42
- "gitHead": "77827e88044adc541963a1ae3b6edb5a71ac0d51"
42
+ "gitHead": "13e7bcee639a97612e1227b7ffb5287c78cbe522"
43
43
  }