@steedos-widgets/amis-lib 1.3.4-beta.1 → 1.3.4-beta.3

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/index.esm.js CHANGED
@@ -1208,7 +1208,7 @@ var frontend_display_type_is_split = "分栏视图";
1208
1208
  var frontend_display_as = "显示为";
1209
1209
  var frontend_record_sum = "个项目";
1210
1210
  var frontend_button_reload_tooltip = "刷新";
1211
- var frontend_button_search_tooltip = "查询";
1211
+ var frontend_button_search_tooltip = "筛选";
1212
1212
  var frontend_fields_filter_button_search = "搜索";
1213
1213
  var frontend_fields_filter_button_settings = "设置搜索项";
1214
1214
  var frontend_button_listview_control_tooltip = "列表视图控制";
@@ -2916,7 +2916,7 @@ const getObjectDetailButtonsSchemas = (objectSchema, recordId, ctx)=>{
2916
2916
  type: "steedos-dropdown-button",
2917
2917
  label: "",
2918
2918
  buttons: moreButtons,
2919
- className: 'slds-icon',
2919
+ className: 'slds-icon ml-1',
2920
2920
  visibleOn: moreButtonsVisibleOn
2921
2921
  };
2922
2922
  buttons.push(dropdownButtonsSchema);
@@ -3659,13 +3659,15 @@ function getObjectListHeaderFirstLine(objectSchema, listViewName, ctx) {
3659
3659
  "visibleOn": "${display == 'split'?false:true}"
3660
3660
  }];
3661
3661
  if(ctx.formFactor !== 'SMALL'){
3662
+ const restButtons = Array.isArray(amisButtonsSchema) ? amisButtonsSchema.filter(obj => obj.name !== "standard_new"):[];
3662
3663
  buttonSchema.push({
3663
3664
  "type": "flex",
3664
3665
  "items":[
3665
3666
  standardNewButton,
3666
- {
3667
+ (restButtons.length > 0) && {
3667
3668
  "type": "dropdown-button",
3668
- "buttons": Array.isArray(amisButtonsSchema) ? amisButtonsSchema.filter(obj => obj.name !== "standard_new"):{},
3669
+ "buttons": restButtons,
3670
+ "className": " ml-1",
3669
3671
  "menuClassName": "p-none split-dropdown-buttons",
3670
3672
  "align": "right",
3671
3673
  "size": "sm"
@@ -3797,7 +3799,6 @@ async function getObjectListHeaderSecordLine(objectSchema, listViewName, ctx) {
3797
3799
  },
3798
3800
  {
3799
3801
  "body": [
3800
- fieldsFilterButtonSchema,
3801
3802
  {
3802
3803
  "type": "button",
3803
3804
  "label": "",
@@ -3806,6 +3807,7 @@ async function getObjectListHeaderSecordLine(objectSchema, listViewName, ctx) {
3806
3807
  "target": amisListViewId,
3807
3808
  "className": "bg-white p-2 rounded border-gray-300 text-gray-500"
3808
3809
  },
3810
+ fieldsFilterButtonSchema,
3809
3811
  // {
3810
3812
  // "type": "button",
3811
3813
  // "label": "",
@@ -4053,7 +4055,7 @@ async function getObjectRecordDetailRelatedListHeader(relatedObjectSchema, relat
4053
4055
  "body": [
4054
4056
  {
4055
4057
  "type": "tpl",
4056
- "tpl": `<a class="text-black text-base font-bold" href="/app/\${appId}/\${_master.objectName}/\${_master.recordId}/\${objectName}/grid?related_field_name=\${relatedKey}">${relatedLabel}(\${$count})</a>`,
4058
+ "tpl": `<a class="text-black text-base font-bold hover:font-bold" href="/app/\${appId}/\${_master.objectName}/\${_master.recordId}/\${objectName}/grid?related_field_name=\${relatedKey}">${relatedLabel}(\${$count})</a>`,
4057
4059
  "inline": false,
4058
4060
  "wrapperComponent": "",
4059
4061
  "className": "",
@@ -5142,7 +5144,7 @@ function getObjectHeaderQuickSearchBox(mainObject, fields, formFactor, { isLooku
5142
5144
  {
5143
5145
  "type": "search-box",
5144
5146
  "name": keywordsSearchBoxName,
5145
- "placeholder": "快速搜索",
5147
+ "placeholder": "搜索此列表",
5146
5148
  "value": crudKeywords,
5147
5149
  "clearable": true,
5148
5150
  "clearAndSubmit": true
@@ -5265,10 +5267,10 @@ function getObjectHeaderToolbar(mainObject, fields, formFactor, {
5265
5267
  if(toolbarCount){
5266
5268
  toolbars.push(toolbarCount);
5267
5269
  }
5268
- toolbars.push(toolbarReloadButton);
5269
5270
  if(toolbarFilter){
5270
5271
  toolbars.push(toolbarFilter);
5271
5272
  }
5273
+ toolbars.push(toolbarReloadButton);
5272
5274
  toolbars.push(toolbarDisplayAsButton);
5273
5275
  toolbars.push(toolbarDQuickSearchBox);
5274
5276
  return [
@@ -5284,10 +5286,10 @@ function getObjectHeaderToolbar(mainObject, fields, formFactor, {
5284
5286
  toolbars.push(toolbarFilter);
5285
5287
  }
5286
5288
  toolbars.push(toolbarReloadButton);
5289
+ toolbars.push(toolbarDisplayAsButton);
5287
5290
  if(mainObject?.permissions?.allowCreateListViews){
5288
5291
  toolbars.push(getSettingListviewToolbarButtonSchema());
5289
5292
  }
5290
- toolbars.push(toolbarDisplayAsButton);
5291
5293
  toolbars.push(toolbarDQuickSearchBox);
5292
5294
  return [
5293
5295
  // "filter-toggler",
@@ -8267,7 +8269,7 @@ async function getTableOperation(ctx){
8267
8269
  label: i18next.t('frontend_operation'),
8268
8270
  fixed: 'right',
8269
8271
  labelClassName: 'text-center',
8270
- className: 'text-center steedos-listview-operation w-20',
8272
+ className: 'text-center steedos-listview-operation w-10',
8271
8273
  buttons: [
8272
8274
  {
8273
8275
  "type": "steedos-dropdown-button",
@@ -8323,7 +8325,7 @@ async function getTableSchema$1(fields, options){
8323
8325
  return {
8324
8326
  mode: "table",
8325
8327
  name: "thelist",
8326
- headerToolbarClassName: "py-2 px-2 border-gray-300 bg-gray-100 border-solid border-b",
8328
+ headerToolbarClassName: "py-2 px-2 border-gray-300 border-solid border-b",
8327
8329
  className: "",
8328
8330
  draggable: false,
8329
8331
  defaultParams: getDefaultParams(options),
@@ -10691,7 +10693,7 @@ async function getRecordDetailRelatedListSchema(objectName, recordId, relatedObj
10691
10693
  setDataToComponentId: componentId,
10692
10694
  // tableHiddenOn: hiddenEmptyTable ? "this.$count === 0" : null,
10693
10695
  appId: appId,
10694
- crudClassName: 'border-t border-slate-300 hidden',
10696
+ crudClassName: 'border-t border-gray-300 hidden',
10695
10697
  ...ctx
10696
10698
  };
10697
10699
  const amisSchema= (await getRelatedListSchema(relatedObjectName, 'all', options)).amisSchema;
@@ -10703,7 +10705,7 @@ async function getRecordDetailRelatedListSchema(objectName, recordId, relatedObj
10703
10705
  amisSchema: {
10704
10706
  type: "service",
10705
10707
  id: componentId,
10706
- className: `steedos-record-related-list ${componentId} rounded border border-slate-300 bg-gray-100 mb-4 ${className}`,
10708
+ className: `steedos-record-related-list ${componentId} rounded border border-gray-300 bg-gray-100 mb-4 ${className}`,
10707
10709
  data: {
10708
10710
  relatedKey: relatedKey,
10709
10711
  listViewId: `amis-\${appId}-${relatedObjectName}-listview`,
@@ -11389,7 +11391,7 @@ async function getRecordDetailSchema(objectName, appId, props = {}){
11389
11391
  };
11390
11392
  const content = {
11391
11393
  "type": "tabs",
11392
- "className": "sm:mt-3 bg-white sm:shadow sm:rounded sm:border border-slate-300 p-4",
11394
+ "className": "sm:mt-3 bg-white sm:shadow sm:rounded sm:border border-gray-300 p-4",
11393
11395
  "tabs": [
11394
11396
  detailed
11395
11397
  ],
@@ -11576,7 +11578,7 @@ async function getListPageInitSchema(objectApiName, formFactor, userSession) {
11576
11578
  "columnsTogglable": false,
11577
11579
  "showHeader": true,
11578
11580
  // "headerSchema": headerSchema
11579
- className: "sm:border bg-white sm:shadow sm:rounded border-slate-300 border-solid"
11581
+ className: "sm:border bg-white sm:shadow sm:rounded border-gray-300 border-solid"
11580
11582
  }]
11581
11583
  }
11582
11584
  }
@@ -11634,7 +11636,7 @@ async function getRecordPageInitSchema(objectApiName){
11634
11636
  ]
11635
11637
  }
11636
11638
  ],
11637
- "className": "sm:mt-3 flex flex-col region-main bg-white sm:shadow sm:rounded sm:border border-slate-300",
11639
+ "className": "sm:mt-3 flex flex-col region-main bg-white sm:shadow sm:rounded sm:border border-gray-300",
11638
11640
  "linksClassName": "pl-4 pt-2"
11639
11641
  };
11640
11642
  if(relatedList.length){