bullet_train-themes-hayabusa 1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.bt-link +0 -0
- data/MIT-LICENSE +20 -0
- data/README.md +28 -0
- data/Rakefile +8 -0
- data/app/assets/config/bullet_train_themes_hayabusa_manifest.js +0 -0
- data/app/assets/stylesheets/hayabusa/actiontext.css +26 -0
- data/app/assets/stylesheets/hayabusa/application.css +33 -0
- data/app/assets/stylesheets/hayabusa/electron.css +46 -0
- data/app/assets/stylesheets/hayabusa/fields/cloudinary_image.css +58 -0
- data/app/assets/stylesheets/hayabusa/fields/date_field.css +19 -0
- data/app/assets/stylesheets/hayabusa/fields/index.css +5 -0
- data/app/assets/stylesheets/hayabusa/fields/phone_field.css +7 -0
- data/app/assets/stylesheets/hayabusa/fields/super_select.css +103 -0
- data/app/assets/stylesheets/hayabusa/fields/trix_editor.css +90 -0
- data/app/assets/stylesheets/hayabusa/mailer.scss +359 -0
- data/app/assets/stylesheets/hayabusa/tailwind/colors.css +25 -0
- data/app/assets/stylesheets/hayabusa/tailwind/components.css +151 -0
- data/app/assets/stylesheets/hayabusa/tailwind/dark-mode.css +218 -0
- data/app/assets/stylesheets/hayabusa/tailwind/utilities.css +49 -0
- data/app/assets/stylesheets/hayabusa/turn.css +44 -0
- data/app/assets/stylesheets/hayabusa.tailwind.css +5 -0
- data/app/assets/stylesheets/tailwindcss/base.css +1 -0
- data/app/assets/stylesheets/tailwindcss/components.css +1 -0
- data/app/assets/stylesheets/tailwindcss/utilities.css +1 -0
- data/app/javascript/application.hayabusa.js +0 -0
- data/app/views/themes/hayabusa/_alert.html.erb +13 -0
- data/app/views/themes/hayabusa/_box.html.erb +66 -0
- data/app/views/themes/hayabusa/_breadcrumb.html.erb +23 -0
- data/app/views/themes/hayabusa/_cell.html.erb +41 -0
- data/app/views/themes/hayabusa/_decision_line.html.erb +12 -0
- data/app/views/themes/hayabusa/_line.html.erb +3 -0
- data/app/views/themes/hayabusa/_notices.html.erb +15 -0
- data/app/views/themes/hayabusa/_page.html.erb +12 -0
- data/app/views/themes/hayabusa/_title.html.erb +20 -0
- data/app/views/themes/hayabusa/attributes/_base.html.erb +30 -0
- data/app/views/themes/hayabusa/attributes/_block.html.erb +9 -0
- data/app/views/themes/hayabusa/breadcrumbs/_actions.html.erb +22 -0
- data/app/views/themes/hayabusa/commentary/_box.html.erb +13 -0
- data/app/views/themes/hayabusa/conversations/_card.html.erb +21 -0
- data/app/views/themes/hayabusa/conversations/_comment.html.erb +26 -0
- data/app/views/themes/hayabusa/conversations/_message.html.erb +136 -0
- data/app/views/themes/hayabusa/conversations/_thread_border.html.erb +3 -0
- data/app/views/themes/hayabusa/fields/_field.html.erb +81 -0
- data/app/views/themes/hayabusa/forms/_errors.html.erb +14 -0
- data/app/views/themes/hayabusa/layouts/_account.html.erb +139 -0
- data/app/views/themes/hayabusa/layouts/_devise.html.erb +11 -0
- data/app/views/themes/hayabusa/layouts/_head.html.erb +8 -0
- data/app/views/themes/hayabusa/layouts/_mailer.html.erb +429 -0
- data/app/views/themes/hayabusa/memberships/_photos.html.erb +18 -0
- data/app/views/themes/hayabusa/menu/_heading.html.erb +3 -0
- data/app/views/themes/hayabusa/menu/_item.html.erb +16 -0
- data/app/views/themes/hayabusa/menu/_section.html.erb +7 -0
- data/app/views/themes/hayabusa/workflow/_box.html.erb +30 -0
- data/config/routes.rb +2 -0
- data/lib/bullet_train/themes/hayabusa/engine.rb +12 -0
- data/lib/bullet_train/themes/hayabusa/version.rb +7 -0
- data/lib/bullet_train/themes/hayabusa.rb +15 -0
- data/lib/tasks/bullet_train/themes/hayabusa_tasks.rake +53 -0
- data/tailwind.hayabusa.config.js +96 -0
- metadata +146 -0
@@ -0,0 +1,429 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
2
|
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3
|
+
<head>
|
4
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
6
|
+
<title>Welcome to <%= t('application.name') %>!</title>
|
7
|
+
|
8
|
+
<%= stylesheet_link_tag 'application', media: 'all'%>
|
9
|
+
<%= stylesheet_link_tag 'application.mailer.light', media: 'all' %>
|
10
|
+
|
11
|
+
<% # TODO replace with Tailwind CSS styles. %>
|
12
|
+
<style type="text/css">
|
13
|
+
*:not(br):not(tr):not(html) {
|
14
|
+
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
|
15
|
+
box-sizing: border-box;
|
16
|
+
}
|
17
|
+
|
18
|
+
body {
|
19
|
+
width: 100% !important;
|
20
|
+
height: 100%;
|
21
|
+
margin: 0;
|
22
|
+
line-height: 1.4;
|
23
|
+
background-color: #F6F7F8;
|
24
|
+
color: #3E4B5B;
|
25
|
+
font-size: 16px;
|
26
|
+
-webkit-text-size-adjust: none;
|
27
|
+
}
|
28
|
+
|
29
|
+
p,
|
30
|
+
ul,
|
31
|
+
ol,
|
32
|
+
blockquote {
|
33
|
+
line-height: 1.4;
|
34
|
+
text-align: left;
|
35
|
+
}
|
36
|
+
|
37
|
+
a {
|
38
|
+
color: #047BF8;
|
39
|
+
}
|
40
|
+
|
41
|
+
a img {
|
42
|
+
border: none;
|
43
|
+
}
|
44
|
+
/* Layout ------------------------------ */
|
45
|
+
|
46
|
+
.email-wrapper {
|
47
|
+
width: 100%;
|
48
|
+
margin: 0;
|
49
|
+
padding: 0;
|
50
|
+
background-color: #F6F7F8;
|
51
|
+
}
|
52
|
+
|
53
|
+
.email-content {
|
54
|
+
width: 100%;
|
55
|
+
margin: 0;
|
56
|
+
padding: 0;
|
57
|
+
}
|
58
|
+
/* Masthead ----------------------- */
|
59
|
+
|
60
|
+
.email-masthead {
|
61
|
+
padding: 25px 0;
|
62
|
+
text-align: center;
|
63
|
+
}
|
64
|
+
|
65
|
+
.email-masthead_logo {
|
66
|
+
width: 94px;
|
67
|
+
}
|
68
|
+
|
69
|
+
.email-masthead_name {
|
70
|
+
font-size: 16px;
|
71
|
+
/*font-weight: bold;*/
|
72
|
+
color: #bbbfc3;
|
73
|
+
text-decoration: none;
|
74
|
+
/*text-shadow: 0 1px 0 white;*/
|
75
|
+
}
|
76
|
+
/* Body ------------------------------ */
|
77
|
+
|
78
|
+
.email-body {
|
79
|
+
width: 100%;
|
80
|
+
margin: 0;
|
81
|
+
padding: 0;
|
82
|
+
border-top: 1px solid #EDEFF2;
|
83
|
+
border-bottom: 1px solid #EDEFF2;
|
84
|
+
background-color: #FFFFFF;
|
85
|
+
|
86
|
+
}
|
87
|
+
|
88
|
+
.email-body_inner {
|
89
|
+
width: 570px;
|
90
|
+
margin: 0 auto;
|
91
|
+
padding: 0;
|
92
|
+
background-color: #FFFFFF;
|
93
|
+
}
|
94
|
+
|
95
|
+
.email-footer {
|
96
|
+
width: 570px;
|
97
|
+
margin: 0 auto;
|
98
|
+
padding: 0;
|
99
|
+
text-align: center;
|
100
|
+
}
|
101
|
+
|
102
|
+
.email-footer p {
|
103
|
+
color: #AAAAAA;
|
104
|
+
}
|
105
|
+
|
106
|
+
.body-action {
|
107
|
+
width: 100%;
|
108
|
+
margin: 30px auto;
|
109
|
+
padding: 0;
|
110
|
+
text-align: center;
|
111
|
+
}
|
112
|
+
|
113
|
+
.body-sub {
|
114
|
+
margin-top: 25px;
|
115
|
+
padding-top: 25px;
|
116
|
+
border-top: 1px solid #EDEFF2;
|
117
|
+
}
|
118
|
+
|
119
|
+
.content-cell {
|
120
|
+
padding: 35px;
|
121
|
+
}
|
122
|
+
|
123
|
+
.preheader {
|
124
|
+
display: none !important;
|
125
|
+
}
|
126
|
+
/* Attribute list ------------------------------ */
|
127
|
+
|
128
|
+
.attributes {
|
129
|
+
margin: 0 0 21px;
|
130
|
+
}
|
131
|
+
|
132
|
+
.attributes_content {
|
133
|
+
background-color: #EDEFF2;
|
134
|
+
padding: 16px;
|
135
|
+
}
|
136
|
+
|
137
|
+
.attributes_item {
|
138
|
+
padding: 0;
|
139
|
+
}
|
140
|
+
/* Related Items ------------------------------ */
|
141
|
+
|
142
|
+
.related {
|
143
|
+
width: 100%;
|
144
|
+
margin: 0;
|
145
|
+
padding: 25px 0 0 0;
|
146
|
+
}
|
147
|
+
|
148
|
+
.related_item {
|
149
|
+
padding: 10px 0;
|
150
|
+
color: #3E4B5B;
|
151
|
+
font-size: 15px;
|
152
|
+
line-height: 18px;
|
153
|
+
}
|
154
|
+
|
155
|
+
.related_item-title {
|
156
|
+
display: block;
|
157
|
+
margin: .5em 0 0;
|
158
|
+
}
|
159
|
+
|
160
|
+
.related_item-thumb {
|
161
|
+
display: block;
|
162
|
+
padding-bottom: 10px;
|
163
|
+
}
|
164
|
+
|
165
|
+
.related_heading {
|
166
|
+
border-top: 1px solid #EDEFF2;
|
167
|
+
text-align: center;
|
168
|
+
padding: 25px 0 10px;
|
169
|
+
}
|
170
|
+
/* Discount Code ------------------------------ */
|
171
|
+
|
172
|
+
.discount {
|
173
|
+
width: 100%;
|
174
|
+
margin: 0;
|
175
|
+
padding: 24px;
|
176
|
+
background-color: #EDEFF2;
|
177
|
+
border: 2px dashed #9BA2AB;
|
178
|
+
}
|
179
|
+
|
180
|
+
.discount_heading {
|
181
|
+
text-align: center;
|
182
|
+
}
|
183
|
+
|
184
|
+
.discount_body {
|
185
|
+
text-align: center;
|
186
|
+
font-size: 15px;
|
187
|
+
}
|
188
|
+
/* Social Icons ------------------------------ */
|
189
|
+
|
190
|
+
.social {
|
191
|
+
width: auto;
|
192
|
+
}
|
193
|
+
|
194
|
+
.social td {
|
195
|
+
padding: 0;
|
196
|
+
width: auto;
|
197
|
+
}
|
198
|
+
|
199
|
+
.social_icon {
|
200
|
+
height: 20px;
|
201
|
+
margin: 0 8px 10px 8px;
|
202
|
+
padding: 0;
|
203
|
+
}
|
204
|
+
/* Data table ------------------------------ */
|
205
|
+
|
206
|
+
.purchase {
|
207
|
+
width: 100%;
|
208
|
+
margin: 0;
|
209
|
+
padding: 35px 0;
|
210
|
+
}
|
211
|
+
|
212
|
+
.purchase_content {
|
213
|
+
width: 100%;
|
214
|
+
margin: 0;
|
215
|
+
padding: 25px 0 0 0;
|
216
|
+
}
|
217
|
+
|
218
|
+
.purchase_item {
|
219
|
+
padding: 10px 0;
|
220
|
+
color: #3E4B5B;
|
221
|
+
font-size: 15px;
|
222
|
+
line-height: 18px;
|
223
|
+
}
|
224
|
+
|
225
|
+
.purchase_heading {
|
226
|
+
padding-bottom: 8px;
|
227
|
+
border-bottom: 1px solid #EDEFF2;
|
228
|
+
}
|
229
|
+
|
230
|
+
.purchase_heading p {
|
231
|
+
margin: 0;
|
232
|
+
color: #9BA2AB;
|
233
|
+
font-size: 12px;
|
234
|
+
}
|
235
|
+
|
236
|
+
.purchase_footer {
|
237
|
+
padding-top: 15px;
|
238
|
+
border-top: 1px solid #EDEFF2;
|
239
|
+
}
|
240
|
+
|
241
|
+
.purchase_total {
|
242
|
+
margin: 0;
|
243
|
+
text-align: right;
|
244
|
+
/*font-weight: bold;*/
|
245
|
+
color: #3E4B5B;
|
246
|
+
}
|
247
|
+
|
248
|
+
.purchase_total--label {
|
249
|
+
padding: 0 15px 0 0;
|
250
|
+
}
|
251
|
+
/* Utilities ------------------------------ */
|
252
|
+
|
253
|
+
.align-right {
|
254
|
+
text-align: right;
|
255
|
+
}
|
256
|
+
|
257
|
+
.align-left {
|
258
|
+
text-align: left;
|
259
|
+
}
|
260
|
+
|
261
|
+
.align-center {
|
262
|
+
text-align: center;
|
263
|
+
}
|
264
|
+
/*Media Queries ------------------------------ */
|
265
|
+
|
266
|
+
@media only screen and (max-width: 600px) {
|
267
|
+
.email-body_inner,
|
268
|
+
.email-footer {
|
269
|
+
width: 100% !important;
|
270
|
+
}
|
271
|
+
}
|
272
|
+
|
273
|
+
@media only screen and (max-width: 500px) {
|
274
|
+
.button {
|
275
|
+
width: 100% !important;
|
276
|
+
}
|
277
|
+
}
|
278
|
+
/* Buttons ------------------------------ */
|
279
|
+
|
280
|
+
.button {
|
281
|
+
background-color: #047BF8;
|
282
|
+
border-top: 10px solid #047BF8;
|
283
|
+
border-right: 18px solid #047BF8;
|
284
|
+
border-bottom: 10px solid #047BF8;
|
285
|
+
border-left: 18px solid #047BF8;
|
286
|
+
display: inline-block;
|
287
|
+
color: #FFF;
|
288
|
+
text-decoration: none;
|
289
|
+
border-radius: 3px;
|
290
|
+
-webkit-text-size-adjust: none;
|
291
|
+
line-height: 22px;
|
292
|
+
font-size: 16px;
|
293
|
+
color: #FFF;
|
294
|
+
}
|
295
|
+
|
296
|
+
.button--link {
|
297
|
+
background-color: transparent;
|
298
|
+
border-top: 10px solid transparent;
|
299
|
+
border-right: 18px solid transparent;
|
300
|
+
border-bottom: 10px solid transparent;
|
301
|
+
border-left: 18px solid transparent;
|
302
|
+
display: inline-block;
|
303
|
+
color: #047BF8;
|
304
|
+
text-decoration: underline;
|
305
|
+
border-radius: 3px;
|
306
|
+
/*box-shadow: 0 2px 3px rgba(0, 0, 0, 0.16);*/
|
307
|
+
-webkit-text-size-adjust: none;
|
308
|
+
}
|
309
|
+
|
310
|
+
.button--green {
|
311
|
+
background-color: #22BC66;
|
312
|
+
border-top: 10px solid #22BC66;
|
313
|
+
border-right: 18px solid #22BC66;
|
314
|
+
border-bottom: 10px solid #22BC66;
|
315
|
+
border-left: 18px solid #22BC66;
|
316
|
+
}
|
317
|
+
|
318
|
+
.button--red {
|
319
|
+
background-color: #FF6136;
|
320
|
+
border-top: 10px solid #FF6136;
|
321
|
+
border-right: 18px solid #FF6136;
|
322
|
+
border-bottom: 10px solid #FF6136;
|
323
|
+
border-left: 18px solid #FF6136;
|
324
|
+
}
|
325
|
+
/* Type ------------------------------ */
|
326
|
+
|
327
|
+
h1 {
|
328
|
+
margin-top: 0;
|
329
|
+
color: #3E4B5B;
|
330
|
+
font-size: 19px;
|
331
|
+
font-weight: bold;
|
332
|
+
text-align: left;
|
333
|
+
}
|
334
|
+
|
335
|
+
h2 {
|
336
|
+
margin-top: 0;
|
337
|
+
color: #3E4B5B;
|
338
|
+
font-size: 16px;
|
339
|
+
font-weight: bold;
|
340
|
+
text-align: left;
|
341
|
+
}
|
342
|
+
|
343
|
+
h3 {
|
344
|
+
margin-top: 0;
|
345
|
+
color: #3E4B5B;
|
346
|
+
font-size: 14px;
|
347
|
+
font-weight: bold;
|
348
|
+
text-align: left;
|
349
|
+
}
|
350
|
+
|
351
|
+
p {
|
352
|
+
margin-top: 0;
|
353
|
+
color: #3E4B5B;
|
354
|
+
font-size: 16px;
|
355
|
+
line-height: 1.5em;
|
356
|
+
text-align: left;
|
357
|
+
}
|
358
|
+
|
359
|
+
p.sub {
|
360
|
+
font-size: 12px;
|
361
|
+
}
|
362
|
+
|
363
|
+
p.center {
|
364
|
+
text-align: center;
|
365
|
+
}
|
366
|
+
|
367
|
+
.body-action.less-footer {
|
368
|
+
margin-bottom: 10px;
|
369
|
+
}
|
370
|
+
</style>
|
371
|
+
</head>
|
372
|
+
<body>
|
373
|
+
<% if content_for? :preheader %>
|
374
|
+
<span class="preheader"><% yield :preheader %></span>
|
375
|
+
<% end %>
|
376
|
+
<table class="email-wrapper" width="100%" cellpadding="0" cellspacing="0">
|
377
|
+
<tr>
|
378
|
+
<td align="center">
|
379
|
+
<table class="email-content" width="100%" cellpadding="0" cellspacing="0">
|
380
|
+
<tr>
|
381
|
+
<td class="email-masthead">
|
382
|
+
<a href="<%= root_url %>" class="email-masthead_name">
|
383
|
+
<%= email_image_tag("logo/logo.png", width: image_width_for_height("logo/logo.png", BulletTrain::Themes.logo_height), height: BulletTrain::Themes.logo_height, style: "width: #{image_width_for_height('logo/logo.png', BulletTrain::Themes.logo_height)}px; height: #{BulletTrain::Themes.logo_height}px;") %>
|
384
|
+
</a>
|
385
|
+
</td>
|
386
|
+
</tr>
|
387
|
+
<!-- Email Body -->
|
388
|
+
<tr>
|
389
|
+
<td class="email-body" width="100%" cellpadding="0" cellspacing="0">
|
390
|
+
<table class="email-body_inner" align="center" width="570" cellpadding="0" cellspacing="0">
|
391
|
+
<!-- Body content -->
|
392
|
+
<tr>
|
393
|
+
<td class="content-cell">
|
394
|
+
|
395
|
+
<%= yield %>
|
396
|
+
|
397
|
+
<% if false %>
|
398
|
+
<!-- Sub copy -->
|
399
|
+
<table class="body-sub">
|
400
|
+
<tr>
|
401
|
+
<td>
|
402
|
+
<p class="sub"><%= t('.trouble') %></p>
|
403
|
+
<p class="sub">{{action_url}}</p>
|
404
|
+
</td>
|
405
|
+
</tr>
|
406
|
+
</table>
|
407
|
+
<% end %>
|
408
|
+
</td>
|
409
|
+
</tr>
|
410
|
+
</table>
|
411
|
+
</td>
|
412
|
+
</tr>
|
413
|
+
<tr>
|
414
|
+
<td>
|
415
|
+
<table class="email-footer" align="center" width="570" cellpadding="0" cellspacing="0">
|
416
|
+
<tr>
|
417
|
+
<td class="content-cell" align="center">
|
418
|
+
<p class="sub align-center">© <%= t('layouts.mailer.all_rights_reserved', year: Date.today.year, product_name: t('application.name')) %></p>
|
419
|
+
</td>
|
420
|
+
</tr>
|
421
|
+
</table>
|
422
|
+
</td>
|
423
|
+
</tr>
|
424
|
+
</table>
|
425
|
+
</td>
|
426
|
+
</tr>
|
427
|
+
</table>
|
428
|
+
</body>
|
429
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<% size ||= 12 %>
|
2
|
+
<% align ||= nil %>
|
3
|
+
|
4
|
+
<% valid_sizes = [7, 9, 12] %>
|
5
|
+
<% raise "Invalid membership photo size: #{size}. Valid options are #{valid_sizes.to_sentence}." unless valid_sizes.include?(size) %>
|
6
|
+
|
7
|
+
<div class="flex overflow-hidden <%= 'place-content-center' if align == :center %>">
|
8
|
+
<% memberships.each_with_index do |membership, index| %>
|
9
|
+
<%= image_tag membership_profile_photo_url(membership), class: "#{'-ml-1' if index > 0} inline-block h-#{size} w-#{size} rounded-full ring-2 ring-white dark:ring-transparent" %>
|
10
|
+
<% end %>
|
11
|
+
</div>
|
12
|
+
|
13
|
+
<% # we have to list out the evaluations we want possible above so purgecss includes them in production. %>
|
14
|
+
<% if false %>
|
15
|
+
<div class="h-12 w-12"></div>
|
16
|
+
<div class="h-9 w-9"></div>
|
17
|
+
<div class="h-7 w-7"></div>
|
18
|
+
<% end %>
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<% yield p = np %>
|
2
|
+
|
3
|
+
<% method ||= nil %>
|
4
|
+
<% active ||= request.path == url %>
|
5
|
+
|
6
|
+
<%= send (method ? :button_to : :link_to), url, class: "block group hover:no-underline hover-indent-child #{'border border-pink-400 dark:bg-black dark:bg-opacity-10' if active} px-2 py-2 dark:text-white", method: method do %>
|
7
|
+
<div class="inline-block indent-child flex items-center text-primary-500">
|
8
|
+
<!-- Heroicon name: home -->
|
9
|
+
<% if p.content_for? :icon %>
|
10
|
+
<span class="text-pink-500 mr-3 h-6 w-6 text-center text-xl leading-6 dark:text-gray-400">
|
11
|
+
<%= p.content_for :icon %>
|
12
|
+
</span>
|
13
|
+
<% end %>
|
14
|
+
<%= label %>
|
15
|
+
</div>
|
16
|
+
<% end %>
|
@@ -0,0 +1,30 @@
|
|
1
|
+
<% yield p = np %>
|
2
|
+
|
3
|
+
<% width ||= "max-w-md" %>
|
4
|
+
|
5
|
+
<div class="min-h-screen flex flex-col justify-center sm:py-12">
|
6
|
+
<div class="mx-auto w-full <%= width %> p-1.5">
|
7
|
+
<div class="bg-white py-8 px-10 shadow rounded-lg dark:bg-darkPrimary-700">
|
8
|
+
<div class="sm:mx-auto sm:w-full sm:max-w-md py-5">
|
9
|
+
<a href="<%= main_app.root_path %>" class="block py-3">
|
10
|
+
<img alt="" src="<%= image_path("logo/logo.png") %>" width="<%= image_width_for_height("logo/logo.png", BulletTrain::Themes.logo_height) %>" height="<%= BulletTrain::Themes.logo_height %>" class="mx-auto h-12 w-auto" />
|
11
|
+
</a>
|
12
|
+
|
13
|
+
<h1 class="mt-6 text-center text-3xl font-semibold tracking-tight dark:text-white">
|
14
|
+
<%= p.yield :title %>
|
15
|
+
</h1>
|
16
|
+
|
17
|
+
<%= render "shared/line" %>
|
18
|
+
</div>
|
19
|
+
|
20
|
+
<div class="electron-undraggable pt-5 space-y-5">
|
21
|
+
<%= p.content_for :body %>
|
22
|
+
</div>
|
23
|
+
</div>
|
24
|
+
</div>
|
25
|
+
</div>
|
26
|
+
|
27
|
+
<% # We have to list out every option we want to be available at runtime so they're included in our Tailwind output. %>
|
28
|
+
<% if false %>
|
29
|
+
<div class="max-w-md max-w-lg"></div>
|
30
|
+
<% end %>
|
data/config/routes.rb
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
module BulletTrain
|
2
|
+
module Themes
|
3
|
+
module Hayabusa
|
4
|
+
class Engine < ::Rails::Engine
|
5
|
+
initializer "bullet_train.themes.hayabusa.register" do |app|
|
6
|
+
BulletTrain::Themes.themes[:hayabusa] = BulletTrain::Themes::Hayabusa::Theme.new
|
7
|
+
BulletTrain.linked_gems << "bullet_train-themes-hayabusa"
|
8
|
+
end
|
9
|
+
end
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
require "bullet_train/themes/hayabusa/version"
|
2
|
+
require "bullet_train/themes/hayabusa/engine"
|
3
|
+
require "bullet_train/themes/light"
|
4
|
+
|
5
|
+
module BulletTrain
|
6
|
+
module Themes
|
7
|
+
module Hayabusa
|
8
|
+
class Theme < BulletTrain::Themes::Light::Theme
|
9
|
+
def directory_order
|
10
|
+
["hayabusa"] + super
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -0,0 +1,53 @@
|
|
1
|
+
namespace :bullet_train do
|
2
|
+
namespace :themes do
|
3
|
+
namespace :hayabusa do
|
4
|
+
desc "Fork the \"Hayabusa\" theme into your local repository."
|
5
|
+
task :eject, [:destination] => :environment do |task, args|
|
6
|
+
theme_base_path = `bundle show --paths bullet_train-themes-hayabusa`.chomp
|
7
|
+
puts "Ejecting from Hayabusa theme in `#{theme_base_path}`."
|
8
|
+
|
9
|
+
puts "Ejecting Tailwind configuration into `./tailwind.#{args[:destination]}.config.js`."
|
10
|
+
`cp #{theme_base_path}/tailwind.hayabusa.config.js #{Rails.root}/tailwind.#{args[:destination]}.config.js`
|
11
|
+
|
12
|
+
puts "Ejecting stylesheets into `./app/assets/stylesheets/#{args[:destination]}`."
|
13
|
+
`mkdir #{Rails.root}/app/assets/stylesheets`
|
14
|
+
`cp -R #{theme_base_path}/app/assets/stylesheets/hayabusa #{Rails.root}/app/assets/stylesheets/#{args[:destination]}`
|
15
|
+
`cp -R #{theme_base_path}/app/assets/stylesheets/hayabusa.tailwind.css #{Rails.root}/app/assets/stylesheets/#{args[:destination]}.tailwind.css`
|
16
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/hayabusa/#{args[:destination]}/g" #{Rails.root}/app/assets/stylesheets/#{args[:destination]}.tailwind.css`
|
17
|
+
|
18
|
+
puts "Ejecting JavaScript into `./app/javascript/application.#{args[:destination]}.js`."
|
19
|
+
`cp #{theme_base_path}/app/javascript/application.hayabusa.js #{Rails.root}/app/javascript/application.#{args[:destination]}.js`
|
20
|
+
|
21
|
+
puts "Ejecting all theme partials into `./app/views/themes/#{args[:destination]}`."
|
22
|
+
`mkdir #{Rails.root}/app/views/themes`
|
23
|
+
`cp -R #{theme_base_path}/app/views/themes/hayabusa #{Rails.root}/app/views/themes/#{args[:destination]}`
|
24
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/hayabusa/#{args[:destination]}/g" #{Rails.root}/app/views/themes/#{args[:destination]}/layouts/_head.html.erb`
|
25
|
+
|
26
|
+
puts "Cutting local `Procfile.dev` over from `hayabusa` to `#{args[:destination]}`."
|
27
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/hayabusa/#{args[:destination]}/g" #{Rails.root}/Procfile.dev`
|
28
|
+
|
29
|
+
puts "Cutting local `package.json` over from `hayabusa` to `#{args[:destination]}`."
|
30
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/hayabusa/#{args[:destination]}/g" #{Rails.root}/package.json`
|
31
|
+
|
32
|
+
# Stub out the class that represents this theme and establishes its inheritance structure.
|
33
|
+
target_path = "#{Rails.root}/app/lib/bullet_train/themes/#{args[:destination]}.rb"
|
34
|
+
puts "Stubbing out a class that represents this theme in `./#{target_path}`."
|
35
|
+
`mkdir -p #{Rails.root}/app/lib/bullet_train/themes`
|
36
|
+
`cp #{theme_base_path}/lib/bullet_train/themes/hayabusa.rb #{target_path}`
|
37
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/module Hayabusa/module #{args[:destination].titlecase}/g" #{target_path}`
|
38
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/TailwindCss/Hayabusa/g" #{target_path}`
|
39
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/hayabusa/#{args[:destination]}/g" #{target_path}`
|
40
|
+
["require", "TODO", "mattr_accessor"].each do |thing_to_remove|
|
41
|
+
`grep -v #{thing_to_remove} #{target_path} > #{target_path}.tmp`
|
42
|
+
`mv #{target_path}.tmp #{target_path}`
|
43
|
+
end
|
44
|
+
`standardrb --fix #{target_path}`
|
45
|
+
|
46
|
+
puts "Cutting local project over from `hayabusa` to `#{args[:destination]}` in `app/helpers/application_helper.rb`."
|
47
|
+
`sed -i #{'""' if `echo $OSTYPE`.include?("darwin")} "s/:hayabusa/:#{args[:destination]}/g" #{Rails.root}/app/helpers/application_helper.rb`
|
48
|
+
|
49
|
+
puts "You must restart `bin/dev` at this point, because of the changes to `Procfile.dev` and `package.json`."
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|