-
Notifications
You must be signed in to change notification settings - Fork 0
/
warning-button.html
209 lines (189 loc) · 10.5 KB
/
warning-button.html
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
<!DOCTYPE html>
<html lang="en-us" ng-app="website">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<title>BigCommerce Pattern Lab</title>
<link rel="shortcut icon" href="https://cdn6.bigcommerce.com/r-d9855a91e0124a20a1d8b36949bceaafdb22a7f1/img/bc_favicon.ico" />
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400italic,600,600italic">
<link rel="stylesheet" href="css/bcapp-pattern-lab.css" />
<link rel="stylesheet" href="css/website.css" />
</head>
<body>
<nav class="navBar topNavBar">
<div class="container">
<ul class="navBar-section topNavBar-section">
<li class="navBar-item topNavBar-item">
<a href="/">
<picture class="navBar-picture">
<img class="navBar-logo-condensed" src="/svg/logo.svg" alt="BigCommerce Logo" />
<img class="navBar-logo" src="/svg/bclogo.svg" alt="BigCommerce Logo" />
</picture>
</a>
</li>
<li class="navBar-item topNavBar-item">
<div class="topNavBar-label">
Pattern Lab (v2.12.1)
</div>
</li>
</ul>
<ul class="navBar-section navBar-section--alt topNavBar-section--alt">
<li class="navBar-item topNavBar-item ">
<a class="navBar-action topNavBar-action" href="/style.html">Style</a>
</li>
<li class="navBar-item topNavBar-item ">
<a class="navBar-action topNavBar-action" href="/components.html">Components</a>
</li>
<li class="navBar-item topNavBar-item is-active">
<a class="navBar-action topNavBar-action" href="/patterns.html">Patterns</a>
</li>
<li class="navBar-item topNavBar-item ">
<a class="navBar-action topNavBar-action" href="/app-containers.html">Layouts</a>
</li>
<li class="navBar-item topNavBar-item ">
<a class="navBar-action topNavBar-action" href="/utils.html">Developer Utilities</a>
</li>
<li class="navBar-item topNavBar-item ">
<a class="navBar-action topNavBar-action" href="https://github.com/bigcommerce-labs/bcapp-pattern-lab/releases">Change Log</a>
</li>
</ul>
</div>
</nav>
<div class="container">
<aside class="aside" ng-controller="AsideNavCtrl">
<nav class="asideNav">
<h2 class="asideNav-header">
<a class="asideNav-header-link" href="/patterns.html">
Patterns
</a>
</h2>
<ul class="asideNav-list">
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/action-bar.html')}">
<a class="asideNav-link" href="/action-bar.html">Action Bar</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/color-picker.html')}">
<a class="asideNav-link" href="/color-picker.html">Color Picker</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/copy-clipboard.html')}">
<a class="asideNav-link" href="/copy-clipboard.html">Copy to Clipboard</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/credit-card.html')}">
<a class="asideNav-link" href="/credit-card.html">Credit Card Payment</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/data-tables.html')}">
<a class="asideNav-link" href="/data-tables.html">Data Tables</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/date-picker.html')}">
<a class="asideNav-link" href="/date-picker.html">Date Picker</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/loading-states.html')}">
<a class="asideNav-link" href="/loading-states.html">Loading States</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/prompt.html')}">
<a class="asideNav-link" href="/prompt.html">Prompts</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/navigation.html')}">
<a class="asideNav-link" href="/navigation.html">Navigation</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/alerts.html')}">
<a class="asideNav-link" href="/alerts.html">Notifications and Alerts</a>
</li>
<li class="asideNav-listItem" ng-class="{'is-active': isActive('/warning-button.html')}">
<a class="asideNav-link" href="/warning-button.html">Warning Button</a>
</li>
</ul>
</nav>
</aside>
<main class="mainContent" role="main" ng-view>
<h1 class="mainContent-header">Warning Button</h1>
<p>
The warning button is used as a revert action and is required to be followed up with a prompt to confirm that the user is okay with taking this action (i.e. Remove, Delete, or Disconnect).
</p>
<section class="panel labPanel">
<h4 class="labPanel-title">Subcomponents</h4>
<ul class="u-listNoBullet labRelated-list">
<li>
<a href="/prompt.html">Prompt</a>
</li>
</ul>
</section>
<hr />
<section class="panel labPanel">
<div class="labPanel-docs">
<div class="labPanel-docsDemo">
<a href="/demo.html#/components/warning-button" class="button--icon demo-button" target="_blank">
View Demo <icon glyph="ic-open-in-new"></icon>
</a>
</div>
<tabset buttons="true">
<tab>
<tab-heading>Design</tab-heading>
<div class="labPanel-content demo">
<button class="button button--warning">Warning Button</button>
<button class="button button--warning" disabled>Disabled Warning Button</button>
</div>
<div class="labPanel-content">
<h4 class="labPanel-title">Rules:</h4>
<div class="labPanel-classDefs">
<p>The warning button is used as a revert action and is required to be followed up with a prompt to confirm that the user is okay with taking this action (i.e. Remove, Delete, or Disconnect).</p>
<p>There can only be one warning button present if it is used in the action bar or if it is in a group of buttons.</p>
<p>If there is a delete/remove action it should always be red to be consistent all over the control panel (example even in the dropdown, the delete action text is red)</p>
</div>
</div>
</tab>
<tab>
<tab-heading>Developer</tab-heading>
<div class="labPanel-content">
<textarea ui-codemirror="{
'lineNumbers': true,
'theme':'default',
'readOnly': 'true',
'lineWrapping' : false,
'mode': 'text/html',
autoClearEmptyLines: true
}">
<div class="modal-background"></div>
<section class="modal prompt">
<!-- The following section is taken from the template you specify -->
<div class="prompt-body">
<p>
Are you sure you want to take this action?
</p>
</div>
<div class="prompt-footer">
<a class="prompt-footer-link" ng-click="modalContentCtrl.cancel($event)" href="#">Cancel</a>
<a class="button button--small button--primary prompt-footer-button" ng-click="modalContentCtrl.ok($event)" href="#">OK</a>
</div>
</section>
<button class="button button--warning" ng-click="modalCtrl.openPrompt($event)">Warning Button</button></textarea>
</div>
<div class="labPanel-content">
<h4 class="labPanel-title">Rules:</h4>
<div class="labPanel-classDefs">
<p>
1. <code>.button--warning</code>
<ul class="u-listNoBullet">
<li>This button action has to be followed by a prompt (confirmation of the action that will be taken).</li>
</ul>
</p>
</div>
</div>
</tab>
</tabset>
</div>
</section>
</main>
</div>
<script src="js/vendor.js"></script>
<!-- build:patternLabJS -->
<script src="js/bcapp/bcapp-pattern-lab-all-deps.js"></script>
<script src="js/bcapp/bcapp-pattern-lab-all-templates.js"></script>
<script src="js/bcapp/bcapp-pattern-lab-components.js"></script>
<!-- endbuild -->
<!-- build:websiteJS -->
<script src="js/website/website-templates.js"></script>
<script src="js/website/website.js"></script>
<!-- endbuild -->
</body>
</html>