@wcardinal/wcardinal-ui 0.441.0 → 0.443.0

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 (67) hide show
  1. package/dist/types/wcardinal/ui/d-picker-color.d.ts +3 -0
  2. package/dist/types/wcardinal/ui/d-table-column-state.d.ts +4 -1
  3. package/dist/types/wcardinal/ui/d-table-state.d.ts +4 -0
  4. package/dist/types/wcardinal/ui/theme/common/new-svg-rounded-checkerboard.d.ts +1 -0
  5. package/dist/types/wcardinal/ui/theme/common/new-svg-rounded-rect.d.ts +1 -0
  6. package/dist/types/wcardinal/ui/theme/dark/d-theme-dark-picker-color.d.ts +3 -0
  7. package/dist/types/wcardinal/ui/theme/dark/new-dark-svg-rounded-checkerboard.d.ts +1 -0
  8. package/dist/types/wcardinal/ui/theme/white/d-theme-white-picker-color.d.ts +3 -0
  9. package/dist/types/wcardinal/ui/theme/white/new-white-svg-rounded-checkerboard.d.ts +1 -0
  10. package/dist/wcardinal/ui/d-dynamic-text.js +3 -8
  11. package/dist/wcardinal/ui/d-dynamic-text.js.map +1 -1
  12. package/dist/wcardinal/ui/d-image-piece-impl.js +8 -0
  13. package/dist/wcardinal/ui/d-image-piece-impl.js.map +1 -1
  14. package/dist/wcardinal/ui/d-image-piece-layouter-part-container.js +1 -1
  15. package/dist/wcardinal/ui/d-image-piece-layouter-part-container.js.map +1 -1
  16. package/dist/wcardinal/ui/d-picker-color.js +5 -4
  17. package/dist/wcardinal/ui/d-picker-color.js.map +1 -1
  18. package/dist/wcardinal/ui/d-table-body.js +3 -2
  19. package/dist/wcardinal/ui/d-table-body.js.map +1 -1
  20. package/dist/wcardinal/ui/d-table-column-state.js.map +1 -1
  21. package/dist/wcardinal/ui/d-table-state.js +4 -0
  22. package/dist/wcardinal/ui/d-table-state.js.map +1 -1
  23. package/dist/wcardinal/ui/theme/common/new-svg-rounded-checkerboard.js +20 -0
  24. package/dist/wcardinal/ui/theme/common/new-svg-rounded-checkerboard.js.map +1 -0
  25. package/dist/wcardinal/ui/theme/common/new-svg-rounded-rect.js +15 -0
  26. package/dist/wcardinal/ui/theme/common/new-svg-rounded-rect.js.map +1 -0
  27. package/dist/wcardinal/ui/theme/dark/d-theme-dark-button-color-gradient.js +2 -5
  28. package/dist/wcardinal/ui/theme/dark/d-theme-dark-button-color-gradient.js.map +1 -1
  29. package/dist/wcardinal/ui/theme/dark/d-theme-dark-button-color.js +3 -6
  30. package/dist/wcardinal/ui/theme/dark/d-theme-dark-button-color.js.map +1 -1
  31. package/dist/wcardinal/ui/theme/dark/d-theme-dark-picker-color.js +24 -35
  32. package/dist/wcardinal/ui/theme/dark/d-theme-dark-picker-color.js.map +1 -1
  33. package/dist/wcardinal/ui/theme/dark/d-theme-dark-table-body-cells.js +7 -2
  34. package/dist/wcardinal/ui/theme/dark/d-theme-dark-table-body-cells.js.map +1 -1
  35. package/dist/wcardinal/ui/theme/dark/new-dark-svg-rounded-checkerboard.js +5 -0
  36. package/dist/wcardinal/ui/theme/dark/new-dark-svg-rounded-checkerboard.js.map +1 -0
  37. package/dist/wcardinal/ui/theme/white/d-theme-white-button-color-gradient.js +2 -5
  38. package/dist/wcardinal/ui/theme/white/d-theme-white-button-color-gradient.js.map +1 -1
  39. package/dist/wcardinal/ui/theme/white/d-theme-white-button-color.js +3 -6
  40. package/dist/wcardinal/ui/theme/white/d-theme-white-button-color.js.map +1 -1
  41. package/dist/wcardinal/ui/theme/white/d-theme-white-picker-color.js +24 -35
  42. package/dist/wcardinal/ui/theme/white/d-theme-white-picker-color.js.map +1 -1
  43. package/dist/wcardinal/ui/theme/white/d-theme-white-table-body-cells.js +7 -2
  44. package/dist/wcardinal/ui/theme/white/d-theme-white-table-body-cells.js.map +1 -1
  45. package/dist/wcardinal/ui/theme/white/new-white-svg-rounded-checkerboard.js +5 -0
  46. package/dist/wcardinal/ui/theme/white/new-white-svg-rounded-checkerboard.js.map +1 -0
  47. package/dist/wcardinal-ui-theme-dark-en-us.js +71 -49
  48. package/dist/wcardinal-ui-theme-dark-en-us.min.js +2 -2
  49. package/dist/wcardinal-ui-theme-dark-en-us.min.js.map +1 -1
  50. package/dist/wcardinal-ui-theme-dark-ja-jp.js +71 -49
  51. package/dist/wcardinal-ui-theme-dark-ja-jp.min.js +2 -2
  52. package/dist/wcardinal-ui-theme-dark-ja-jp.min.js.map +1 -1
  53. package/dist/wcardinal-ui-theme-dark.js +71 -49
  54. package/dist/wcardinal-ui-theme-dark.min.js +2 -2
  55. package/dist/wcardinal-ui-theme-white-en-us.js +71 -49
  56. package/dist/wcardinal-ui-theme-white-en-us.min.js +2 -2
  57. package/dist/wcardinal-ui-theme-white-en-us.min.js.map +1 -1
  58. package/dist/wcardinal-ui-theme-white-ja-jp.js +71 -49
  59. package/dist/wcardinal-ui-theme-white-ja-jp.min.js +2 -2
  60. package/dist/wcardinal-ui-theme-white-ja-jp.min.js.map +1 -1
  61. package/dist/wcardinal-ui-theme-white.js +71 -49
  62. package/dist/wcardinal-ui-theme-white.min.js +2 -2
  63. package/dist/wcardinal-ui.cjs.js +131 -112
  64. package/dist/wcardinal-ui.js +25 -16
  65. package/dist/wcardinal-ui.min.js +2 -2
  66. package/dist/wcardinal-ui.min.js.map +1 -1
  67. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.441.0
2
+ Winter Cardinal UI v0.443.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -6016,16 +6016,27 @@
6016
6016
  DThemes.setDefaultThemeClass(DThemeDark);
6017
6017
  };
6018
6018
 
6019
+ var newSvgRoundedRect = function (x, y, width, height, fill, stroke, strokeWidth, strokeOpacity) {
6020
+ var sw = strokeWidth !== null && strokeWidth !== void 0 ? strokeWidth : 0;
6021
+ var o = sw * 0.5;
6022
+ var r = Math.max(0, 3 - o);
6023
+ var w = width - sw - r - r;
6024
+ var h = height - sw - r - r;
6025
+ x += o + r;
6026
+ y += o;
6027
+ return ("<path d=\"M".concat(x, ",").concat(y, " h").concat(w, " a").concat(r, ",").concat(r, " 0 0 1 ").concat(r, ",").concat(r, " v").concat(h, " a").concat(r, ",").concat(r, " 0 0 1 -").concat(r, ",").concat(r, " h-").concat(w, " a").concat(r, ",").concat(r, " 0 0 1 -").concat(r, ",-").concat(r, " v-").concat(h, " a").concat(r, ",").concat(r, " 0 0 1 ").concat(r, ",-").concat(r, "z\" fill=\"").concat(fill, "\"") +
6028
+ (stroke ? " stroke=\"".concat(stroke, "\"") : "") +
6029
+ (strokeWidth != null ? " stroke-width=\"".concat(strokeWidth, "\"") : "") +
6030
+ (strokeOpacity != null ? " stroke-opacity=\"".concat(strokeOpacity, "\"") : "") +
6031
+ " />");
6032
+ };
6033
+
6019
6034
  /*
6020
6035
  * Copyright (C) 2019 Toshiba Corporation
6021
6036
  * SPDX-License-Identifier: Apache-2.0
6022
6037
  */
6023
- // Material Design icons by Google.
6024
- // Apache license version 2.0.
6025
6038
  /* eslint-disable prettier/prettier */
6026
- DThemeDarkAtlas.add("button_color_sample", 21, 21, "<g transform=\"scale(0.875,0.875)\">" +
6027
- "<path d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z\" fill=\"#fff\"/>" +
6028
- "</g>");
6039
+ DThemeDarkAtlas.add("button_color_sample", 21, 21, newSvgRoundedRect(3, 3, 15, 15, "#fff", "#eee", 1));
6029
6040
  /* eslint-enable prettier/prettier */
6030
6041
  var formatter$8 = function (colorAndAlpha) {
6031
6042
  return "#".concat(UtilRgb.toCode(colorAndAlpha.color), " A").concat(colorAndAlpha.alpha.toFixed(2));
@@ -6036,7 +6047,7 @@
6036
6047
  return _super !== null && _super.apply(this, arguments) || this;
6037
6048
  }
6038
6049
  DThemeDarkButtonColor.prototype.getImageTintColor = function (state) {
6039
- return null;
6050
+ return 0xffffff;
6040
6051
  };
6041
6052
  DThemeDarkButtonColor.prototype.getImageSource = function (state) {
6042
6053
  return DThemeDarkAtlas.mappings.button_color_sample;
@@ -6067,25 +6078,35 @@
6067
6078
 
6068
6079
  const DColorType = wcardinal.ui.DColorType;
6069
6080
 
6081
+ var isPatternInjected = false;
6082
+ var newSvgRoundedCheckerboard = function (width, height, color1, color2, stroke, strokeWidth, strokeOpacity) {
6083
+ var result = "";
6084
+ if (!isPatternInjected) {
6085
+ isPatternInjected = true;
6086
+ result =
6087
+ "<defs>" +
6088
+ "<pattern id=\"rounded-checkerboard-pattern\" patternUnits=\"userSpaceOnUse\" width=\"18\" height=\"18\">" +
6089
+ "<rect x=\"0\" y=\"0\" width=\"9\" height=\"9\" fill=\"".concat(color1, "\" />") +
6090
+ "<rect x=\"9\" y=\"0\" width=\"9\" height=\"9\" fill=\"".concat(color2, "\" />") +
6091
+ "<rect x=\"0\" y=\"9\" width=\"9\" height=\"9\" fill=\"".concat(color2, "\" />") +
6092
+ "<rect x=\"9\" y=\"9\" width=\"9\" height=\"9\" fill=\"".concat(color1, "\" />") +
6093
+ "</pattern>" +
6094
+ "</defs>";
6095
+ }
6096
+ result += newSvgRoundedRect(0, 0, width, height, "url(#rounded-checkerboard-pattern)", stroke, strokeWidth, strokeOpacity);
6097
+ return result;
6098
+ };
6099
+
6100
+ var newDarkSvgRoundedCheckerboard = function (width, height, stroke, strokeWidth, strokeOpacity) {
6101
+ return newSvgRoundedCheckerboard(width, height, "#5f5f5f", "#454545", stroke, strokeWidth, strokeOpacity);
6102
+ };
6103
+
6070
6104
  /*
6071
6105
  * Copyright (C) 2019 Toshiba Corporation
6072
6106
  * SPDX-License-Identifier: Apache-2.0
6073
6107
  */
6074
- var makeCheckerboard = function (width, height) {
6075
- var LIGHT = "#5f5f5f";
6076
- var DARK = "#454545";
6077
- var result = "<g>";
6078
- for (var ih = 0; ih < height; ++ih) {
6079
- for (var iw = 0; iw < width; ++iw) {
6080
- var color = (iw + ih) % 2 === 0 ? LIGHT : DARK;
6081
- result += "<rect x=\"".concat(9 * iw, "\" y=\"").concat(9 * ih, "\" width=\"9\" height=\"9\" fill=\"").concat(color, "\" />");
6082
- }
6083
- }
6084
- result += "</g>";
6085
- return result;
6086
- };
6087
6108
  /* eslint-disable prettier/prettier */
6088
- DThemeDarkAtlas.add("picker_color_main", 236, 164, "<g>" +
6109
+ DThemeDarkAtlas.add("picker_color_main", 234, 162, "<g>" +
6089
6110
  "<linearGradient id=\"fs7w3iusfdnb\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">" +
6090
6111
  "<stop stop-color=\"#FFFFFF\" stop-opacity=\"0\" offset=\"0\"/>" +
6091
6112
  "<stop stop-color=\"#FFFFFF\" stop-opacity=\"1\" offset=\"1\"/>" +
@@ -6094,13 +6115,11 @@
6094
6115
  "<stop stop-color=\"#000000\" stop-opacity=\"0\" offset=\"0\"/>" +
6095
6116
  "<stop stop-color=\"#000000\" stop-opacity=\"1\" offset=\"1\"/>" +
6096
6117
  "</linearGradient>" +
6097
- "<rect x=\"0\" y=\"0\" width=\"236\" height=\"164\" fill=\"url(#fs7w3iusfdnb)\" />" +
6098
- "<rect x=\"0\" y=\"0\" width=\"236\" height=\"164\" fill=\"url(#2rfcfe9874bw)\" />" +
6099
- "</g>", 1, 1, 234, 162);
6100
- DThemeDarkAtlas.add("picker_color_main_base", 236, 164, "<g>" +
6101
- "<rect x=\"0\" y=\"0\" width=\"236\" height=\"164\" fill=\"#fff\" />" +
6102
- "</g>", 1, 1, 234, 162);
6103
- DThemeDarkAtlas.add("picker_color_alpha_checkerboard", 234, 18, makeCheckerboard(26, 2));
6118
+ newSvgRoundedRect(0, 0, 234, 162, "url(#fs7w3iusfdnb)") +
6119
+ newSvgRoundedRect(0, 0, 234, 162, "url(#2rfcfe9874bw)") +
6120
+ "</g>");
6121
+ DThemeDarkAtlas.add("picker_color_main_base", 234, 162, "<rect x=\"0\" y=\"0\" width=\"236\" height=\"164\" fill=\"#fff\" />");
6122
+ DThemeDarkAtlas.add("picker_color_alpha_checkerboard", 234, 18, newDarkSvgRoundedCheckerboard(234, 18));
6104
6123
  DThemeDarkAtlas.add("picker_color_alpha", 234, 18, "<g>" +
6105
6124
  "<linearGradient id=\"s48afbuh44\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">" +
6106
6125
  "<stop stop-color=\"#FFFFFF\" stop-opacity=\"0\" offset=\"0\"/>" +
@@ -6118,20 +6137,15 @@
6118
6137
  "<stop stop-color=\"#FF00FF\" offset=\"0.833\"/>" +
6119
6138
  "<stop stop-color=\"#FF0000\" offset=\"1\"/>" +
6120
6139
  "</linearGradient>" +
6121
- "<rect x=\"0\" y=\"0\" width=\"234\" height=\"18\" fill=\"url(#ni2rbisdf3)\" />" +
6140
+ newSvgRoundedRect(0, 0, 234, 18, "url(#ni2rbisdf3)") +
6122
6141
  "</g>");
6123
6142
  DThemeDarkAtlas.add("picker_color_base_pointer", 16.2, 31.8, "<rect x=\"4.5\" y=\"4.5\" width=\"7.2\" height=\"22.8\" stroke=\"#ffffff\" stroke-width=\"2.4\" fill=\"none\" />");
6124
6143
  DThemeDarkAtlas.add("picker_color_pointer", 25.8, 25.8, "<circle cx=\"12.9\" cy=\"12.9\" r=\"4.8\" stroke=\"#5f5f5f\" stroke-width=\"2.4\" fill=\"none\" />" +
6125
6144
  "<circle cx=\"12.9\" cy=\"12.9\" r=\"7.2\" stroke=\"#ffffff\" stroke-width=\"2.4\" fill=\"none\" />");
6126
- DThemeDarkAtlas.add("picker_color_recent_checkerboard", 36, 36, makeCheckerboard(4, 4), 9, 9, 18, 18);
6127
- DThemeDarkAtlas.add("picker_color_recent", 36, 36, "<g>" +
6128
- "<rect x=\"0\" y=\"0\" width=\"36\" height=\"36\" fill=\"#fff\" />" +
6129
- "<path x=\"0\" y=\"0\" d=\"M9 9 h18 v18 h-18 v-18 m1 1 v16 h16 v-16 h-16 z\" fill=\"#eee\" />" +
6130
- "</g>", 9, 9, 18, 18);
6131
- DThemeDarkAtlas.add("picker_color_sample_checkerboard", 45, 63, makeCheckerboard(5, 7));
6132
- DThemeDarkAtlas.add("picker_color_sample", 47, 65, "<g>" +
6133
- "<rect x=\"0\" y=\"0\" width=\"47\" height=\"65\" fill=\"#fff\" />" +
6134
- "</g>", 1, 1, 45, 63);
6145
+ DThemeDarkAtlas.add("picker_color_recent_checkerboard", 18, 18, newDarkSvgRoundedCheckerboard(18, 18));
6146
+ DThemeDarkAtlas.add("picker_color_recent", 18, 18, newSvgRoundedRect(0, 0, 18, 18, "#fff", "#eee", 1));
6147
+ DThemeDarkAtlas.add("picker_color_sample_checkerboard", 42, 66, newDarkSvgRoundedCheckerboard(42, 66, "#fff", 1, 0));
6148
+ DThemeDarkAtlas.add("picker_color_sample", 42, 66, newSvgRoundedRect(0, 0, 42, 66, "#fff", "#eee", 1));
6135
6149
  DThemeDarkAtlas.add("picker_color_anchor_outlined", 25.8, 25.8, "<circle cx=\"12.9\" cy=\"12.9\" r=\"8.4\" stroke=\"none\" fill=\"#ffffff\" />" +
6136
6150
  "<circle cx=\"12.9\" cy=\"12.9\" r=\"9.6\" stroke=\"#5f5f5f\" stroke-width=\"2.4\" fill=\"none\" />");
6137
6151
  DThemeDarkAtlas.add("picker_color_anchor", 28.2, 28.2, "<circle cx=\"14.1\" cy=\"14.1\" r=\"6\" stroke=\"none\" fill=\"#ffffff\" />" +
@@ -6139,9 +6153,7 @@
6139
6153
  DThemeDarkAtlas.add("picker_color_direction", 12, 30, "<path d=\"M0.6 25.8 L 12.0375 5.9895\" stroke=\"#5f5f5f\" stroke-width=\"1.2\" fill=\"none\" />" +
6140
6154
  "<path d=\"M8.5125 25.8 A 8.475 8.475 0 0 0 4.275 18.4605\" stroke=\"#5f5f5f\" stroke-width=\"1.2\" fill=\"none\" />" +
6141
6155
  "<rect x=\"0.6\" y=\"24.6\" width=\"11.4375\" height=\"1.2\" rx=\"0.6\" ry=\"0.6\" stroke=\"none\" fill=\"#5f5f5f\" />");
6142
- DThemeDarkAtlas.add("picker_color_standard", 18, 18, "<g>" +
6143
- "<rect x=\"0\" y=\"0\" width=\"18\" height=\"18\" fill=\"#fff\" stroke-width=\"1\" stroke=\"#eee\" />" +
6144
- "</g>");
6156
+ DThemeDarkAtlas.add("picker_color_standard", 18, 18, newSvgRoundedRect(0, 0, 18, 18, "#fff", "#eee", 1));
6145
6157
  /* eslint-enable prettier/prettier */
6146
6158
  var DThemeDarkPickerColor = /** @class */ (function (_super) {
6147
6159
  __extends(DThemeDarkPickerColor, _super);
@@ -6233,7 +6245,16 @@
6233
6245
  return this.getBaseMargin();
6234
6246
  };
6235
6247
  DThemeDarkPickerColor.prototype.getInputLabelWidth = function () {
6236
- return 15;
6248
+ return 18;
6249
+ };
6250
+ DThemeDarkPickerColor.prototype.getSampleWidth = function () {
6251
+ return 42;
6252
+ };
6253
+ DThemeDarkPickerColor.prototype.getSampleHeight = function () {
6254
+ return 66;
6255
+ };
6256
+ DThemeDarkPickerColor.prototype.getSampleMargin = function () {
6257
+ return this.getBaseMargin();
6237
6258
  };
6238
6259
  DThemeDarkPickerColor.prototype.getSampleCheckerboardOldTexture = function () {
6239
6260
  return DThemeDarkAtlas.mappings.picker_color_sample_checkerboard;
@@ -6330,12 +6351,8 @@
6330
6351
  * Copyright (C) 2019 Toshiba Corporation
6331
6352
  * SPDX-License-Identifier: Apache-2.0
6332
6353
  */
6333
- // Material Design icons by Google.
6334
- // Apache license version 2.0.
6335
6354
  /* eslint-disable prettier/prettier */
6336
- DThemeDarkAtlas.add("button_color_gradient_sample", 21, 21, "<g transform=\"scale(0.875,0.875)\">" +
6337
- "<path d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z\" fill=\"#fff\"/>" +
6338
- "</g>");
6355
+ DThemeDarkAtlas.add("button_color_gradient_sample", 21, 21, newSvgRoundedRect(3, 3, 15, 15, "#fff", "#eee", 1));
6339
6356
  /* eslint-enable prettier/prettier */
6340
6357
  var formatter$7 = function () {
6341
6358
  return "";
@@ -8430,8 +8447,13 @@
8430
8447
  return DThemeDarkConstants.COLOR;
8431
8448
  };
8432
8449
  DThemeDarkTableBodyCells.getAlpha = function (state) {
8433
- if (state.inEnabled) {
8434
- return 1.0;
8450
+ if (state.in(DTableState.HAS_DATA)) {
8451
+ if (state.inEnabled) {
8452
+ return 1.0;
8453
+ }
8454
+ else {
8455
+ return 0.5;
8456
+ }
8435
8457
  }
8436
8458
  return 0;
8437
8459
  };