gd-bs 6.6.58 → 6.6.59

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.
@@ -15,10 +15,60 @@ var __extends = (this && this.__extends) || (function () {
15
15
  };
16
16
  })();
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.Jumbotron = void 0;
18
+ exports.Jumbotron = exports.JumbotronTypeClassNames = exports.JumbotronSizeClassNames = exports.JumbotronTypes = exports.JumbotronSize = void 0;
19
19
  var base_1 = require("../base");
20
+ var classNames_1 = require("../classNames");
20
21
  var common_1 = require("../common");
21
22
  var templates_1 = require("./templates");
23
+ /**
24
+ * Jumbotron Size
25
+ */
26
+ var JumbotronSize;
27
+ (function (JumbotronSize) {
28
+ JumbotronSize[JumbotronSize["XSmall"] = 1] = "XSmall";
29
+ JumbotronSize[JumbotronSize["Small"] = 2] = "Small";
30
+ JumbotronSize[JumbotronSize["Medium"] = 3] = "Medium";
31
+ JumbotronSize[JumbotronSize["Large"] = 4] = "Large";
32
+ JumbotronSize[JumbotronSize["XLarge"] = 5] = "XLarge";
33
+ })(JumbotronSize = exports.JumbotronSize || (exports.JumbotronSize = {}));
34
+ /**
35
+ * Jumbotron Types
36
+ */
37
+ var JumbotronTypes;
38
+ (function (JumbotronTypes) {
39
+ JumbotronTypes[JumbotronTypes["Danger"] = 1] = "Danger";
40
+ JumbotronTypes[JumbotronTypes["Dark"] = 2] = "Dark";
41
+ JumbotronTypes[JumbotronTypes["Info"] = 3] = "Info";
42
+ JumbotronTypes[JumbotronTypes["Light"] = 4] = "Light";
43
+ JumbotronTypes[JumbotronTypes["Primary"] = 5] = "Primary";
44
+ JumbotronTypes[JumbotronTypes["Secondary"] = 6] = "Secondary";
45
+ JumbotronTypes[JumbotronTypes["Success"] = 7] = "Success";
46
+ JumbotronTypes[JumbotronTypes["Warning"] = 8] = "Warning";
47
+ })(JumbotronTypes = exports.JumbotronTypes || (exports.JumbotronTypes = {}));
48
+ /**
49
+ * Jumbotron Classes
50
+ */
51
+ exports.JumbotronSizeClassNames = new classNames_1.ClassNames([
52
+ "py-1",
53
+ "py-2",
54
+ "py-3",
55
+ "py-4",
56
+ "py-5"
57
+ ]);
58
+ /**
59
+ * Jumbotron Classes
60
+ */
61
+ exports.JumbotronTypeClassNames = new classNames_1.ClassNames([
62
+ "jumbotron-danger",
63
+ "jumbotron-dark",
64
+ "jumbotron-info",
65
+ "jumbotron-light",
66
+ "jumbotron-link",
67
+ "jumbotron-primary",
68
+ "jumbotron-secondary",
69
+ "jumbotron-success",
70
+ "jumbotron-warning"
71
+ ]);
22
72
  /**
23
73
  * Jumbotron
24
74
  */
@@ -64,6 +114,14 @@ var _Jumbotron = /** @class */ (function (_super) {
64
114
  this.el.removeChild(lead);
65
115
  }
66
116
  }
117
+ // Set the size
118
+ var className = exports.JumbotronSizeClassNames.getByType(this.props.size) || exports.JumbotronSizeClassNames.getByType(JumbotronSize.XLarge);
119
+ this.el.classList.add(className);
120
+ // Set the type
121
+ className = exports.JumbotronTypeClassNames.getByType(this.props.type);
122
+ if (className) {
123
+ this.el.classList.add(className);
124
+ }
67
125
  // Append the content
68
126
  (0, common_1.appendContent)(this.el, this.props.content);
69
127
  };
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HTML = void 0;
4
- exports.HTML = "\n<div class=\"row py-5 m-0\">\n <h1 class=\"display-4\"></h1>\n <p class=\"lead\"></p>\n</div>".trim();
4
+ exports.HTML = "\n<div class=\"jumbotron row m-0\">\n <h1 class=\"display-4\"></h1>\n <p class=\"lead\"></p>\n</div>".trim();