This repository was archived by the owner on Jul 30, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdefault.js
More file actions
92 lines (92 loc) · 5.7 KB
/
default.js
File metadata and controls
92 lines (92 loc) · 5.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
"use strict";
var __extends = (this && this.__extends) || (function () {
var extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
return function (d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
var React = require("react");
var sample_base_1 = require("../common/sample-base");
require("./default.css");
var Default = (function (_super) {
__extends(Default, _super);
function Default() {
return _super !== null && _super.apply(this, arguments) || this;
}
Default.prototype.render = function () {
return (React.createElement("div", { className: 'control-pane' },
React.createElement("div", { className: 'control-section default' },
React.createElement("div", { className: "sample_container badge-default" },
React.createElement("div", { className: "e-btn-group e-custom-button" },
React.createElement("button", { id: "update", className: "e-btn" },
"Updates",
React.createElement("span", { className: "e-badge e-badge-info e-badge-notification e-badge-overlap" }, "14")),
React.createElement("button", { id: "task", className: "e-btn" },
"Tasks",
React.createElement("span", { className: "e-badge e-badge-success e-badge-notification e-badge-overlap" }, "48")),
React.createElement("button", { id: "notify", className: "e-btn" },
"Notifications",
React.createElement("span", { className: "e-badge e-badge-secondary e-badge-notification e-badge-overlap" }, "99"))))),
React.createElement("div", { id: "action-description" },
React.createElement("p", null,
"This sample demonstrates the default functionalities of the badge. To apply the badge, add",
React.createElement("code", null, ".e-badge"),
" class to the target element.")),
React.createElement("div", { id: "description" },
React.createElement("p", null,
"The Badge is a component which is developed in pure CSS and designed in",
React.createElement("code", null, "em"),
" relative units, so that badge will always be in relevant to the parent and makes the badge super easy to customize."),
React.createElement("p", null, "For example, to increase the size of the badge, increase the font-size, width, and height."),
React.createElement("p", null, "There are 6 different types of badges as follows: "),
React.createElement("ul", null,
React.createElement("li", null,
"Default badge: To get the default badge, add the",
React.createElement("code", null, ".e-badge"),
" class to the target element."),
React.createElement("li", null,
"Notification badge: To get the notification badge, add the",
React.createElement("code", null, ".e-badge-notification"),
" class with",
React.createElement("code", null, ".e-badge"),
" and change the wrapper element to",
React.createElement("code", null, "position: relative"),
" property."),
React.createElement("li", null,
"Circle badge: To get the circle badge, add the",
React.createElement("code", null, ".e-badge-circle"),
" class with",
React.createElement("code", null, ".e-badge"),
"."),
React.createElement("li", null,
"Pill badge: To get the pill badge, add the",
React.createElement("code", null, ".e-badge-pill"),
" class with",
React.createElement("code", null, ".e-badge"),
"."),
React.createElement("li", null,
"Dot badge: To get the dot badge, add the",
React.createElement("code", null, ".e-badge-dot"),
" class with",
React.createElement("code", null, ".e-badge"),
" and change the wrapper element to",
React.createElement("code", null, "position: relative"),
" property.")),
React.createElement("p", null, "The badge component supports two positions, and this is applicable only to notification and dot badge."),
React.createElement("ul", null,
React.createElement("li", null, "Top: It is the default position, so there is no additional class needed for the top position."),
React.createElement("li", null,
"Bottom: To get the bottom badge, add the",
React.createElement("code", null, ".e-.badge-bottom"),
" class with",
React.createElement("code", null, ".e-badge"),
".")))));
};
return Default;
}(sample_base_1.SampleBase));
exports.Default = Default;