bemer 0.4.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE-RU.txt +1 -1
- data/LICENSE.txt +1 -1
- data/README.md +99 -84
- data/docs//320/232/320/276/320/275/321/202/320/265/320/272/321/201/321/202-/321/203/320/267/320/273/320/260.md +2 -2
- data/docs//320/240/320/265/320/266/320/270/320/274/321/213.md +2 -2
- data/docs//320/244/320/260/320/270/314/206/320/273/320/276/320/262/320/260/321/217-/321/201/321/202/321/200/321/203/320/272/321/202/321/203/321/200/320/260.md +12 -12
- data/docs//320/245/320/265/320/273/320/277/320/265/321/200-define_templates.md +3 -3
- data/docs//320/250/320/260/320/261/320/273/320/276/320/275/321/213.md +1 -1
- data/lib/bemer/builders/template.rb +1 -1
- data/lib/bemer/builders/template_list.rb +2 -2
- data/lib/bemer/builders/tree/element.rb +1 -1
- data/lib/bemer/builders/tree.rb +2 -2
- data/lib/bemer/component.rb +1 -1
- data/lib/bemer/configuration.rb +1 -0
- data/lib/bemer/context_extentions/template.rb +2 -2
- data/lib/bemer/helpers.rb +5 -5
- data/lib/bemer/path_resolver.rb +10 -6
- data/lib/bemer/pipeline/handler.rb +3 -3
- data/lib/bemer/pipeline.rb +2 -2
- data/lib/bemer/railtie.rb +1 -4
- data/lib/bemer/tag.rb +1 -1
- data/lib/bemer/template_list.rb +1 -1
- data/lib/bemer/tree/base_node.rb +2 -2
- data/lib/bemer/tree/node.rb +3 -3
- data/lib/bemer/tree.rb +1 -1
- data/lib/bemer/version.rb +1 -1
- data/spec/bemer/railtie_spec.rb +1 -1
- metadata +3 -185
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8c61ceea37aaaf31ca46dfc01af60ddade3b934962e5fdfbc87b8cb3be867b29
|
4
|
+
data.tar.gz: 1f56488269559e0ee07b52da4369b8a57fb33fced4204ff0ab5209e2e60a35c8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5d18f1a45d3ea28fbdc17ab7f854fa99ca6b2468dff970855a942eba28674cc4fb09ff8b9403aaa8da76a8b24d99480579dcd0ae78be53dfdd0fba33cca6d914
|
7
|
+
data.tar.gz: 6d9c2c5effef10213f13638cb8b19c1a4bfa5fd88d3774e2be3c12f91d8bc757836fbb8c5f435d4e6a132db1896f8178c33ddaaae079dab211c34b99d4d54373
|
data/LICENSE-RU.txt
CHANGED
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -1,34 +1,32 @@
|
|
1
1
|
# Bemer
|
2
2
|
|
3
|
-
|
3
|
+
1. Build reusable UI components for Ruby on Rails applications.
|
4
|
+
1. Develop Ruby on Rails applications using the `BEM` methodology.
|
4
5
|
|
5
|
-
|
6
|
-
1. Предоставляет функционал для разработки приложений на Ruby on Rails с использованием методологии БЭМ.
|
6
|
+
**IMPORTANT**. *Using the `BEM` methodology is optional.*
|
7
7
|
|
8
|
-
|
8
|
+
Additional resources:
|
9
9
|
|
10
|
-
1.
|
11
|
-
1. [`bemer-simple_form`](https://github.com/vill/bemer-simple_form) -
|
12
|
-
1. [`bemer-bootstrap`](https://github.com/vill/bemer-bootstrap) -
|
13
|
-
1. [
|
10
|
+
1. Habr article in Russian - [Переиспользуемые UI компоненты в приложениях на Ruby on Rails](https://habrahabr.ru/post/352938/).
|
11
|
+
1. [`bemer-simple_form`](https://github.com/vill/bemer-simple_form) - Add the `BEM` methodology to your `SimpleForm` forms.
|
12
|
+
1. [`bemer-bootstrap`](https://github.com/vill/bemer-bootstrap) - Reusable UI components of `Bootstrap`.
|
13
|
+
1. [Ruby on Rails application](https://github.com/vill/bemer-example) using `bemer` and [`bemer-bootstrap`](https://github.com/vill/bemer-bootstrap).
|
14
14
|
|
15
|
-
##
|
15
|
+
## Installation
|
16
16
|
|
17
|
-
|
17
|
+
Add it to your Gemfile:
|
18
18
|
|
19
19
|
```ruby
|
20
20
|
gem 'bemer'
|
21
21
|
```
|
22
22
|
|
23
|
-
|
23
|
+
Run the following command to install it:
|
24
24
|
|
25
25
|
$ bundle
|
26
26
|
|
27
|
-
##
|
27
|
+
## Configuration
|
28
28
|
|
29
|
-
|
30
|
-
|
31
|
-
[Конфигурация](docs/%D0%9A%D0%BE%D0%BD%D1%84%D0%B8%D0%B3%D1%83%D1%80%D0%B0%D1%86%D0%B8%D1%8F.md) для `Bemer`:
|
29
|
+
See [configuration documentation](docs/%D0%9A%D0%BE%D0%BD%D1%84%D0%B8%D0%B3%D1%83%D1%80%D0%B0%D1%86%D0%B8%D1%8F.md) for details.
|
32
30
|
|
33
31
|
```ruby
|
34
32
|
# config/initializers/bemer.rb
|
@@ -36,14 +34,15 @@ gem 'bemer'
|
|
36
34
|
Bemer.setup do |config|
|
37
35
|
config.bem = true
|
38
36
|
config.modifier_name_separator = '--'
|
39
|
-
config.path = 'app/frontend/components' #
|
37
|
+
config.path = 'app/frontend/components' # or Webpacker.config.source_path
|
40
38
|
# config.default_path_prefix = lambda { |path, view|
|
41
39
|
# view.controller.class.name.split('::')[0].underscore
|
42
40
|
# }
|
43
41
|
end
|
44
42
|
```
|
45
43
|
|
46
|
-
|
44
|
+
## Integrations
|
45
|
+
### Webpacker
|
47
46
|
|
48
47
|
```yml
|
49
48
|
# config/webpacker.yml
|
@@ -66,42 +65,17 @@ production:
|
|
66
65
|
<<: *default
|
67
66
|
# ...
|
68
67
|
```
|
68
|
+
#### File naming and folder structure
|
69
|
+
See [file naming and folder structure documentation](docs/%D0%A4%D0%B0%D0%B8%CC%86%D0%BB%D0%BE%D0%B2%D0%B0%D1%8F-%D1%81%D1%82%D1%80%D1%83%D0%BA%D1%82%D1%83%D1%80%D0%B0.md) for details.
|
69
70
|
|
70
|
-
### Файловая структура
|
71
|
-
|
72
|
-
Пример [файловой структуры](docs/%D0%A4%D0%B0%D0%B8%CC%86%D0%BB%D0%BE%D0%B2%D0%B0%D1%8F-%D1%81%D1%82%D1%80%D1%83%D0%BA%D1%82%D1%83%D1%80%D0%B0.md) при использовании [`Sprockets`](https://github.com/rails/sprockets-rails):
|
73
71
|
```
|
74
72
|
app/
|
75
|
-
├── assets/
|
76
|
-
| ├── javascripts/
|
77
|
-
| | ├── admin_panel/
|
78
|
-
| | | ├── application.js
|
79
|
-
| | | └── ...
|
80
|
-
| | ├── landing/
|
81
|
-
| | | ├── application.js
|
82
|
-
| | | └── ...
|
83
|
-
| | ├── user_panel/
|
84
|
-
| | | ├── application.js
|
85
|
-
| | | └── ...
|
86
|
-
| | └── ...
|
87
|
-
| ├── stylesheets/
|
88
|
-
| | ├── admin_panel/
|
89
|
-
| | | ├── application.scss
|
90
|
-
| | | └── ...
|
91
|
-
| | ├── landing/
|
92
|
-
| | | ├── application.scss
|
93
|
-
| | | └── ...
|
94
|
-
| | ├── user_panel/
|
95
|
-
| | | ├── application.scss
|
96
|
-
| | | └── ...
|
97
|
-
| | └── ...
|
98
|
-
| └── ...
|
99
73
|
├── frontend/
|
100
74
|
| ├── components/
|
101
75
|
| | ├── common/
|
102
76
|
| | | ├── carousel/
|
103
77
|
| | | | ├── index.slim
|
104
|
-
| | | | ├──
|
78
|
+
| | | | ├── bemhtml.slim
|
105
79
|
| | | | ├── index.js
|
106
80
|
| | | | ├── index.scss
|
107
81
|
| | | | └── ...
|
@@ -127,18 +101,68 @@ app/
|
|
127
101
|
| | ├── user_panel/
|
128
102
|
| | | └── ...
|
129
103
|
| | └── ...
|
104
|
+
| ├── packs/
|
105
|
+
| | ├── admin_panel/
|
106
|
+
| | | ├── application.js
|
107
|
+
| | | └── ...
|
108
|
+
| | ├── landing/
|
109
|
+
| | | ├── application.js
|
110
|
+
| | | └── ...
|
111
|
+
| | ├── user_panel/
|
112
|
+
| | | ├── application.js
|
113
|
+
| | | └── ...
|
114
|
+
| | └── ...
|
130
115
|
| └── ...
|
131
116
|
└── ...
|
132
117
|
```
|
133
|
-
|
118
|
+
|
119
|
+
### Sprockets
|
120
|
+
|
121
|
+
You do not need to do anything, but add additional assets to the asset load path if necessary:
|
122
|
+
|
123
|
+
```ruby
|
124
|
+
# config/initializers/bemer.rb
|
125
|
+
|
126
|
+
Bemer.setup do |config|
|
127
|
+
config.asset_paths << Rails.root.join('some/asset/path')
|
128
|
+
end
|
129
|
+
```
|
130
|
+
|
131
|
+
### File naming and folder structure
|
132
|
+
See [file naming and folder structure documentation](docs/%D0%A4%D0%B0%D0%B8%CC%86%D0%BB%D0%BE%D0%B2%D0%B0%D1%8F-%D1%81%D1%82%D1%80%D1%83%D0%BA%D1%82%D1%83%D1%80%D0%B0.md) for details.
|
133
|
+
|
134
134
|
```
|
135
135
|
app/
|
136
|
+
├── assets/
|
137
|
+
| ├── javascripts/
|
138
|
+
| | ├── admin_panel/
|
139
|
+
| | | ├── application.js
|
140
|
+
| | | └── ...
|
141
|
+
| | ├── landing/
|
142
|
+
| | | ├── application.js
|
143
|
+
| | | └── ...
|
144
|
+
| | ├── user_panel/
|
145
|
+
| | | ├── application.js
|
146
|
+
| | | └── ...
|
147
|
+
| | └── ...
|
148
|
+
| ├── stylesheets/
|
149
|
+
| | ├── admin_panel/
|
150
|
+
| | | ├── application.scss
|
151
|
+
| | | └── ...
|
152
|
+
| | ├── landing/
|
153
|
+
| | | ├── application.scss
|
154
|
+
| | | └── ...
|
155
|
+
| | ├── user_panel/
|
156
|
+
| | | ├── application.scss
|
157
|
+
| | | └── ...
|
158
|
+
| | └── ...
|
159
|
+
| └── ...
|
136
160
|
├── frontend/
|
137
161
|
| ├── components/
|
138
162
|
| | ├── common/
|
139
163
|
| | | ├── carousel/
|
140
164
|
| | | | ├── index.slim
|
141
|
-
| | | | ├──
|
165
|
+
| | | | ├── bemhtml.slim
|
142
166
|
| | | | ├── index.js
|
143
167
|
| | | | ├── index.scss
|
144
168
|
| | | | └── ...
|
@@ -164,24 +188,15 @@ app/
|
|
164
188
|
| | ├── user_panel/
|
165
189
|
| | | └── ...
|
166
190
|
| | └── ...
|
167
|
-
| ├── packs/
|
168
|
-
| | ├── admin_panel/
|
169
|
-
| | | ├── application.js
|
170
|
-
| | | └── ...
|
171
|
-
| | ├── landing/
|
172
|
-
| | | ├── application.js
|
173
|
-
| | | └── ...
|
174
|
-
| | ├── user_panel/
|
175
|
-
| | | ├── application.js
|
176
|
-
| | | └── ...
|
177
|
-
| | └── ...
|
178
191
|
| └── ...
|
179
192
|
└── ...
|
180
193
|
```
|
181
|
-
### Создание `HTML` структуры компонента
|
182
194
|
|
183
|
-
|
184
|
-
|
195
|
+
## Usage
|
196
|
+
|
197
|
+
### Component to which `BEMHTML` templates cannot be applied
|
198
|
+
|
199
|
+
HTML structure of the [Carousel component from Bootstrap](https://getbootstrap.com/docs/4.3/components/carousel/#with-indicators):
|
185
200
|
|
186
201
|
```slim
|
187
202
|
/ app/frontend/components/common/carousel/index.slim
|
@@ -196,19 +211,19 @@ app/
|
|
196
211
|
= image_tag image_url, class: 'd-block w-100'
|
197
212
|
a.carousel-control-prev data-slide="prev" data-target='.carousel' role="button"
|
198
213
|
span.carousel-control-prev-icon aria-hidden="true"
|
199
|
-
span.sr-only
|
214
|
+
span.sr-only Previous
|
200
215
|
a.carousel-control-next data-slide="next" data-target='.carousel' role="button"
|
201
216
|
span.carousel-control-next-icon aria-hidden="true"
|
202
|
-
span.sr-only
|
217
|
+
span.sr-only Next
|
203
218
|
```
|
204
|
-
[
|
219
|
+
[Rendering](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-render_component.md) the `carousel` component in any view or [other UI components](docs/%D0%A1%D0%BE%D0%B7%D0%B4%D0%B0%D0%BD%D0%B8%D0%B5-%D0%B8-%D0%B8%D1%81%D0%BF%D0%BE%D0%BB%D1%8C%D0%B7%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5-UI-%D0%BA%D0%BE%D0%BC%D0%BF%D0%BE%D0%BD%D0%B5%D0%BD%D1%82.md):
|
205
220
|
```slim
|
206
221
|
= render_component :carousel, prefix: :common, image_urls: image_urls, cls: 'carousel-fade'
|
207
222
|
```
|
208
223
|
|
209
|
-
|
224
|
+
### Component to which `BEMHTML` templates can be applied
|
210
225
|
|
211
|
-
|
226
|
+
Tree structure of the [Carousel component from Bootstrap](https://getbootstrap.com/docs/4.3/components/carousel/#with-indicators):
|
212
227
|
|
213
228
|
```slim
|
214
229
|
/ app/frontend/components/common/carousel/index.slim
|
@@ -224,32 +239,32 @@ app/
|
|
224
239
|
= carousel.elem :image, tag: :img, cls: 'd-block w-100', src: image_url
|
225
240
|
= carousel.elem :control_prev, tag: :a, cls: 'carousel-control-prev', 'data-slide': :prev, role: :button, 'data-target': '.carousel'
|
226
241
|
span.carousel-control-prev-icon aria-hidden="true"
|
227
|
-
span.sr-only
|
242
|
+
span.sr-only Previous
|
228
243
|
= carousel.elem :control_next, tag: :a, cls: 'carousel-control-next', 'data-slide': :next, role: :button, 'data-target': '.carousel'
|
229
244
|
span.carousel-control-next-icon aria-hidden="true"
|
230
|
-
span.sr-only
|
245
|
+
span.sr-only Next
|
231
246
|
```
|
232
247
|
|
233
|
-
[
|
248
|
+
[Default template](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-define_templates.md):
|
234
249
|
```slim
|
235
|
-
/ app/frontend/components/common/carousel/
|
250
|
+
/ app/frontend/components/common/carousel/bemhtml.slim
|
236
251
|
|
237
252
|
= define_templates do |template|
|
238
253
|
= template.elem(mods: :active).add_cls :active
|
239
254
|
```
|
240
255
|
|
241
|
-
[
|
256
|
+
[Rendering](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-render_component.md) the `carousel` component in any view or [other UI components](docs/%D0%A1%D0%BE%D0%B7%D0%B4%D0%B0%D0%BD%D0%B8%D0%B5-%D0%B8-%D0%B8%D1%81%D0%BF%D0%BE%D0%BB%D1%8C%D0%B7%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5-UI-%D0%BA%D0%BE%D0%BC%D0%BF%D0%BE%D0%BD%D0%B5%D0%BD%D1%82.md) using [`BEMHTML`](docs/BEMHTML.md) [templates](docs/%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD%D1%8B.md):
|
242
257
|
```slim
|
243
258
|
= render_component :carousel, prefix: :common, image_urls: image_urls do |template|
|
244
259
|
= template.block(:carousel).add_mix :carousel_fade
|
245
260
|
```
|
246
261
|
|
247
|
-
##
|
262
|
+
## Documentation in Russian
|
248
263
|
|
249
|
-
1. [
|
250
|
-
1. [
|
251
|
-
1. [
|
252
|
-
1.
|
264
|
+
1. [File naming and folder structure](docs/%D0%A4%D0%B0%D0%B8%CC%86%D0%BB%D0%BE%D0%B2%D0%B0%D1%8F-%D1%81%D1%82%D1%80%D1%83%D0%BA%D1%82%D1%83%D1%80%D0%B0.md)
|
265
|
+
1. [Configuration](docs/%D0%9A%D0%BE%D0%BD%D1%84%D0%B8%D0%B3%D1%83%D1%80%D0%B0%D1%86%D0%B8%D1%8F.md)
|
266
|
+
1. [Creating and using UI components](docs/%D0%A1%D0%BE%D0%B7%D0%B4%D0%B0%D0%BD%D0%B8%D0%B5-%D0%B8-%D0%B8%D1%81%D0%BF%D0%BE%D0%BB%D1%8C%D0%B7%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5-UI-%D0%BA%D0%BE%D0%BC%D0%BF%D0%BE%D0%BD%D0%B5%D0%BD%D1%82.md)
|
267
|
+
1. Helpers for UI components
|
253
268
|
1. [`define_component`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-define_component.md)
|
254
269
|
1. [`define_templates`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-define_templates.md)
|
255
270
|
1. [`render_component`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-render_component.md)
|
@@ -257,25 +272,25 @@ app/
|
|
257
272
|
1. [`component_pack`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-component_pack.md)
|
258
273
|
1. [`component_asset_path`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-component_asset_path.md)
|
259
274
|
1. [`component_partial_path`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-component_partial_path.md)
|
260
|
-
1.
|
275
|
+
1. Additional helpers for the BEM methodology
|
261
276
|
1. [`bem_attrs_for`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-bem_attrs_for.md)
|
262
277
|
1. [`bem_mix`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-bem_mix.md)
|
263
278
|
1. [`bem_mods`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-bem_mods.md)
|
264
279
|
1. [`block_tag`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-block_tag.md)
|
265
280
|
1. [`elem_tag`](docs/%D0%A5%D0%B5%D0%BB%D0%BF%D0%B5%D1%80-elem_tag.md)
|
266
281
|
1. [BEMHTML](docs/BEMHTML.md)
|
267
|
-
1. [
|
268
|
-
1. [
|
269
|
-
1. [
|
270
|
-
1. [
|
282
|
+
1. [Templates](docs/%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD%D1%8B.md)
|
283
|
+
1. [Node](docs/%D0%9A%D0%BE%D0%BD%D1%82%D0%B5%D0%BA%D1%81%D1%82-%D1%83%D0%B7%D0%BB%D0%B0.md)
|
284
|
+
1. [Predicates](docs/%D0%9F%D1%80%D0%B5%D0%B4%D0%B8%D0%BA%D0%B0%D1%82%D1%8B.md)
|
285
|
+
1. [Modes](docs/%D0%A0%D0%B5%D0%B6%D0%B8%D0%BC%D1%8B.md)
|
271
286
|
|
272
|
-
##
|
287
|
+
## Links
|
273
288
|
|
274
289
|
1. BEM methodology - https://bem.info/methodology/
|
275
290
|
1. Minimal stack for coding client-side JavaScript and templating - https://github.com/bem/bem-core
|
276
291
|
1. Declarative template engine for the browser and server with regular JS syntax - https://github.com/bem/bem-xjst
|
277
292
|
1. BEM Forum - https://bem.info/forum/
|
278
293
|
|
279
|
-
##
|
294
|
+
## License
|
280
295
|
|
281
|
-
Copyright (c) 2017
|
296
|
+
Copyright (c) 2017-2023 Alexander Grigorev. See [LICENSE.txt](LICENSE.txt) for further details.
|
@@ -178,7 +178,7 @@ HTML тег изменить на `small` если текущая сущност
|
|
178
178
|
Позволяет вызвать любой основной режим (`Symbol`) в контексте текущего узла, дополнительно можно передать параметры которые будут доступны в `params`.
|
179
179
|
|
180
180
|
```slim
|
181
|
-
/ Содержимое файла
|
181
|
+
/ Содержимое файла bemhtml.slim компонента alert
|
182
182
|
= define_templates do |template|
|
183
183
|
= template.block(:alert).add_cls ->(node) { "alert-#{node.params.fetch(:type, :info)}" }
|
184
184
|
```
|
@@ -195,7 +195,7 @@ HTML тег изменить на `small` если текущая сущност
|
|
195
195
|
Позволяет вызвать следующий по очередности шаблон для текущего режима, дополнительно можно передать параметры которые будут доступны в `params`.
|
196
196
|
|
197
197
|
```slim
|
198
|
-
/ Содержимое файла
|
198
|
+
/ Содержимое файла bemhtml.slim компонента alert
|
199
199
|
= define_templates do |template|
|
200
200
|
= template.block(:alert).add_cls ->(node) { "alert-#{node.params.fetch(:type, :info)}" }
|
201
201
|
```
|
@@ -20,7 +20,7 @@ app/
|
|
20
20
|
| ├── common/
|
21
21
|
| | ├── alert/
|
22
22
|
| | | ├── index.html.slim
|
23
|
-
| | | ├──
|
23
|
+
| | | ├── bemhtml.slim
|
24
24
|
| | | ├── index.js
|
25
25
|
| | | └── index.css
|
26
26
|
| | └── ...
|
@@ -63,7 +63,7 @@ app/
|
|
63
63
|
```
|
64
64
|
Возможный вариант шаблонов по умолчанию для компонента `alert`:
|
65
65
|
```slim
|
66
|
-
/ Содержимое файла
|
66
|
+
/ Содержимое файла bemhtml.slim компонента alert
|
67
67
|
= define_templates do |template|
|
68
68
|
= template.block(:alert).add_cls :alert_info
|
69
69
|
```
|
@@ -12,7 +12,7 @@ app/
|
|
12
12
|
| | └── ...
|
13
13
|
| ├── top_navbar/
|
14
14
|
| | ├── index.html.slim
|
15
|
-
| | ├──
|
15
|
+
| | ├── bemhtml.slim
|
16
16
|
| | ├── index.js
|
17
17
|
| | ├── index.scss
|
18
18
|
| | └── ...
|
@@ -26,7 +26,7 @@ app/
|
|
26
26
|
|
27
27
|
1. Каталог **обязательно** должен содержать индексный файл для технологии HTML (это может быть: `index.html`, `index.html.slim`, `index.html.erb` и т.д.), который [описывает структуру компонента](Создание-и-использование-UI-компонент.md), используя для этого любой шаблонизатор (`ERB`, `Slim`, `HAML` и др.) или только HTML код.
|
28
28
|
|
29
|
-
1. Если индексный файл технологии HTML для создания структуры (дерева) компонента [использует хелпер `define_component`](Хелпер-define_component.md), тогда каталог может содержать индексный файл для [шаблонов по умолчанию](Хелпер-define_templates.md) (технология `bemhtml`), он должен называться `
|
29
|
+
1. Если индексный файл технологии HTML для создания структуры (дерева) компонента [использует хелпер `define_component`](Хелпер-define_component.md), тогда каталог может содержать индексный файл для [шаблонов по умолчанию](Хелпер-define_templates.md) (технология `bemhtml`), он должен называться `bemhtml` с обязательным указанием шаблонизатора например: `bemhtml.erb`, `bemhtml.slim` и т.д.
|
30
30
|
|
31
31
|
1. Все остальные технологии (`js`, `css`, `md` и т.д.) считаются дополнительными и их можно добавлять по мере необходимости, имена файлов могут быть любыми но для единообразия и удобства лучше использовать `index` в качестве имени:
|
32
32
|
|
@@ -67,13 +67,13 @@ app/
|
|
67
67
|
| ├── common/
|
68
68
|
| | ├── modal/
|
69
69
|
| | | ├── index.html.slim
|
70
|
-
| | | ├──
|
70
|
+
| | | ├── bemhtml.slim
|
71
71
|
| | | ├── index.js
|
72
72
|
| | | ├── index.scss
|
73
73
|
| | | └── ...
|
74
74
|
| | ├── top_navbar/
|
75
75
|
| | | ├── index.html.slim
|
76
|
-
| | | ├──
|
76
|
+
| | | ├── bemhtml.slim
|
77
77
|
| | | ├── index.js
|
78
78
|
| | | ├── index.scss
|
79
79
|
| | | └── ...
|
@@ -81,7 +81,7 @@ app/
|
|
81
81
|
| ├── admin/
|
82
82
|
| | ├── top_navbar/
|
83
83
|
| | | ├── index.html.slim
|
84
|
-
| | | ├──
|
84
|
+
| | | ├── bemhtml.slim
|
85
85
|
| | | ├── index.js
|
86
86
|
| | | ├── index.scss
|
87
87
|
| | | └── ...
|
@@ -89,7 +89,7 @@ app/
|
|
89
89
|
| ├── user/
|
90
90
|
| | ├── top_navbar/
|
91
91
|
| | | ├── index.html.slim
|
92
|
-
| | | ├──
|
92
|
+
| | | ├── bemhtml.slim
|
93
93
|
| | | ├── index.js
|
94
94
|
| | | ├── index.scss
|
95
95
|
| | | └── ...
|
@@ -108,13 +108,13 @@ app/
|
|
108
108
|
| ├── common/
|
109
109
|
| | ├── modal/
|
110
110
|
| | | ├── index.html.slim
|
111
|
-
| | | ├──
|
111
|
+
| | | ├── bemhtml.slim
|
112
112
|
| | | ├── index.js
|
113
113
|
| | | ├── index.scss
|
114
114
|
| | | └── ...
|
115
115
|
| | ├── top_navbar/
|
116
116
|
| | | ├── index.html.slim
|
117
|
-
| | | ├──
|
117
|
+
| | | ├── bemhtml.slim
|
118
118
|
| | | ├── index.js
|
119
119
|
| | | ├── index.scss
|
120
120
|
| | | └── ...
|
@@ -122,7 +122,7 @@ app/
|
|
122
122
|
| ├── desktop/
|
123
123
|
| | ├── top_navbar/
|
124
124
|
| | | ├── index.html.slim
|
125
|
-
| | | ├──
|
125
|
+
| | | ├── bemhtml.slim
|
126
126
|
| | | ├── index.js
|
127
127
|
| | | ├── index.scss
|
128
128
|
| | | └── ...
|
@@ -130,7 +130,7 @@ app/
|
|
130
130
|
| ├── touch_pad/
|
131
131
|
| | ├── top_navbar/
|
132
132
|
| | | ├── index.html.slim
|
133
|
-
| | | ├──
|
133
|
+
| | | ├── bemhtml.slim
|
134
134
|
| | | ├── index.js
|
135
135
|
| | | ├── index.scss
|
136
136
|
| | | └── ...
|
@@ -150,7 +150,7 @@ app/
|
|
150
150
|
| | ├── index.html.slim
|
151
151
|
| | ├── index.html+phone.slim
|
152
152
|
| | ├── index.html+tablet.slim
|
153
|
-
| | ├──
|
153
|
+
| | ├── bemhtml.slim
|
154
154
|
| | ├── index.js
|
155
155
|
| | ├── index.scss
|
156
156
|
| | └── ...
|
@@ -158,7 +158,7 @@ app/
|
|
158
158
|
| | ├── index.html.slim
|
159
159
|
| | ├── index.html+phone.slim
|
160
160
|
| | ├── index.html+tablet.slim
|
161
|
-
| | ├──
|
161
|
+
| | ├── bemhtml.slim
|
162
162
|
| | ├── index.js
|
163
163
|
| | ├── index.scss
|
164
164
|
| | └── ...
|
@@ -17,7 +17,7 @@ app/
|
|
17
17
|
├── bemer_components/
|
18
18
|
| ├── panel/
|
19
19
|
| | ├── index.html.slim
|
20
|
-
| | ├──
|
20
|
+
| | ├── bemhtml.slim
|
21
21
|
| | ├── index.js
|
22
22
|
| | └── index.css
|
23
23
|
| └── ...
|
@@ -71,11 +71,11 @@ app/
|
|
71
71
|
/ <div class="panel-footer">Panel footer</div>
|
72
72
|
/ </div>
|
73
73
|
```
|
74
|
-
С помощью файла `
|
74
|
+
С помощью файла `bemhtml.slim` можно задать дефолтные шаблоны для компонента, которые можно будет переопределить при вызове `render_component` или `refine_component`.
|
75
75
|
|
76
76
|
Возможный вариант шаблонов по умолчанию для компонента `panel`:
|
77
77
|
```slim
|
78
|
-
/ Содержимое файла
|
78
|
+
/ Содержимое файла bemhtml.slim компонента panel
|
79
79
|
= define_templates do |template|
|
80
80
|
= template.block(:panel).add_cls :panel_default
|
81
81
|
```
|
@@ -44,7 +44,7 @@ module Bemer
|
|
44
44
|
block = @block.eql?('*') ? block : @block
|
45
45
|
elem = @element.nil? || @element.eql?('*') ? elem : @element
|
46
46
|
params = { **new_options, **options, condition: condition, block: block, elem: elem }
|
47
|
-
builder = Builders::Template.new(templates, params)
|
47
|
+
builder = Builders::Template.new(templates, **params)
|
48
48
|
|
49
49
|
block_given? ? yield(builder) : builder
|
50
50
|
end
|
@@ -10,7 +10,7 @@ module Bemer
|
|
10
10
|
def block(name = '*', condition = true, **options)
|
11
11
|
params = { **options, condition: condition, block: name, elem: nil }
|
12
12
|
|
13
|
-
builder = Builders::Template.new(templates, params)
|
13
|
+
builder = Builders::Template.new(templates, **params)
|
14
14
|
|
15
15
|
block_given? ? yield(builder) : builder
|
16
16
|
end
|
@@ -18,7 +18,7 @@ module Bemer
|
|
18
18
|
def elem(name = '*', condition = true, block: '*', **options)
|
19
19
|
params = { **options, condition: condition, block: block || '*', elem: name }
|
20
20
|
|
21
|
-
builder = Builders::Template.new(templates, params)
|
21
|
+
builder = Builders::Template.new(templates, **params)
|
22
22
|
|
23
23
|
block_given? ? yield(builder) : builder
|
24
24
|
end
|
data/lib/bemer/builders/tree.rb
CHANGED
@@ -8,11 +8,11 @@ module Bemer
|
|
8
8
|
end
|
9
9
|
|
10
10
|
def block(name = '', **options, &content)
|
11
|
-
tree.add_node(name, options, &content)
|
11
|
+
tree.add_node(name, **options, &content)
|
12
12
|
end
|
13
13
|
|
14
14
|
def elem(block = '', name = '', **options, &content)
|
15
|
-
tree.add_node(block, name, options, &content)
|
15
|
+
tree.add_node(block, name, **options, &content)
|
16
16
|
end
|
17
17
|
|
18
18
|
def text(content = nil, &callback)
|
data/lib/bemer/component.rb
CHANGED
data/lib/bemer/configuration.rb
CHANGED
@@ -18,6 +18,7 @@ module Bemer
|
|
18
18
|
def initialize # rubocop:disable Metrics/MethodLength
|
19
19
|
@asset_paths = []
|
20
20
|
@bem = false
|
21
|
+
# https://github.com/brainspec/enumerize/blob/9dd68ca36d1efed6bc4cec8557a359f34f408d47/lib/enumerize/activerecord.rb#L24
|
21
22
|
# https://github.com/heartcombo/devise/blob/b52e642c0131f7b0d9f2dd24d8607a186f18223e/lib/devise.rb#L301
|
22
23
|
# Gem::Version.new('0.4.1') > Gem::Version.new('0.10.1')
|
23
24
|
# Здесь вроде также используют https://github.com/rspec/rspec-rails/blob/9b7ab39c027a8cb25e2ebe9e0e985756025b0549/Gemfile#L45
|
@@ -4,11 +4,11 @@ module Bemer
|
|
4
4
|
module ContextExtentions
|
5
5
|
module Template
|
6
6
|
def apply_next(**options)
|
7
|
-
node.apply_next(template, options)
|
7
|
+
node.apply_next(template, **options)
|
8
8
|
end
|
9
9
|
|
10
10
|
def apply(mode, **options)
|
11
|
-
node.apply(mode, template, options)
|
11
|
+
node.apply(mode, template, **options)
|
12
12
|
end
|
13
13
|
end
|
14
14
|
end
|
data/lib/bemer/helpers.rb
CHANGED
@@ -3,11 +3,11 @@
|
|
3
3
|
module Bemer
|
4
4
|
module Helpers
|
5
5
|
def block_tag(name = '', **options, &content)
|
6
|
-
Bemer::Tag.new(name, options, &content).render
|
6
|
+
Bemer::Tag.new(name, **options, &content).render
|
7
7
|
end
|
8
8
|
|
9
9
|
def elem_tag(block = '', element = '', **options, &content)
|
10
|
-
Bemer::Tag.new(block, element, options, &content).render
|
10
|
+
Bemer::Tag.new(block, element, **options, &content).render
|
11
11
|
end
|
12
12
|
|
13
13
|
# Использовать mix
|
@@ -30,7 +30,7 @@ module Bemer
|
|
30
30
|
end
|
31
31
|
|
32
32
|
def render_component(path, **options, &block)
|
33
|
-
Bemer::TemplateList.new(self, path, options).compile(&block)
|
33
|
+
Bemer::TemplateList.new(self, path, **options).compile(&block)
|
34
34
|
end
|
35
35
|
|
36
36
|
alias refine_component render_component
|
@@ -40,7 +40,7 @@ module Bemer
|
|
40
40
|
end
|
41
41
|
|
42
42
|
def define_component(**options, &block)
|
43
|
-
Bemer::Component.new(self).render(options, &block)
|
43
|
+
Bemer::Component.new(self).render(**options, &block)
|
44
44
|
end
|
45
45
|
|
46
46
|
def component_pack(&block)
|
@@ -58,7 +58,7 @@ module Bemer
|
|
58
58
|
def bem_attrs_for(block = '', element = nil, **options)
|
59
59
|
js = options[:js].nil? ? true : options.delete(:js)
|
60
60
|
|
61
|
-
Bemer::EntityBuilder.new(block, element, options.merge(bem: true, js: js)).attrs
|
61
|
+
Bemer::EntityBuilder.new(block, element, **options.merge(bem: true, js: js)).attrs
|
62
62
|
end
|
63
63
|
end
|
64
64
|
end
|
data/lib/bemer/path_resolver.rb
CHANGED
@@ -6,14 +6,18 @@ module Bemer
|
|
6
6
|
@view = view
|
7
7
|
end
|
8
8
|
|
9
|
-
def resolve(name, partial = false)
|
10
|
-
|
11
|
-
|
12
|
-
|
9
|
+
def resolve(name, partial = false) # rubocop:disable Metrics/AbcSize
|
10
|
+
name = name.to_s
|
11
|
+
virtual_dir = File.dirname(view.instance_variable_get(:@virtual_path))
|
12
|
+
dirs = [virtual_dir, File.dirname(name).delete('.')].reject(&:blank?)
|
13
|
+
prefixes = [File.join(*dirs).to_s]
|
14
|
+
format = File.extname(name).delete('.') unless partial
|
15
|
+
basename = File.basename(name, '.*')
|
16
|
+
options = { formats: [format.to_sym] } if format
|
13
17
|
|
14
|
-
return
|
18
|
+
return name unless view.lookup_context.exists?(basename, prefixes, partial, **options.to_h)
|
15
19
|
|
16
|
-
File.join(
|
20
|
+
File.join(virtual_dir, name).to_s
|
17
21
|
end
|
18
22
|
|
19
23
|
protected
|
@@ -21,16 +21,16 @@ module Bemer
|
|
21
21
|
def apply_next(current_template, node, **params)
|
22
22
|
position = priorities[current_template.mode][current_template.object_id] + 1
|
23
23
|
|
24
|
-
apply_template(current_template.mode, node, position, params)
|
24
|
+
apply_template(current_template.mode, node, position, **params)
|
25
25
|
end
|
26
26
|
|
27
27
|
def apply(mode, current_template, node, **params)
|
28
28
|
return unless allowable_mode?(mode) && compatible_modes?(mode, current_template.mode)
|
29
29
|
|
30
30
|
if current_template.mode.eql?(mode)
|
31
|
-
apply_next(current_template, node, params)
|
31
|
+
apply_next(current_template, node, **params)
|
32
32
|
else
|
33
|
-
apply_template(mode, node, params)
|
33
|
+
apply_template(mode, node, **params)
|
34
34
|
end
|
35
35
|
end
|
36
36
|
|
data/lib/bemer/pipeline.rb
CHANGED
@@ -48,11 +48,11 @@ module Bemer
|
|
48
48
|
end
|
49
49
|
|
50
50
|
def apply_next(template, node, **params)
|
51
|
-
handler_by(node.name).apply_next(template, node, params)
|
51
|
+
handler_by(node.name).apply_next(template, node, **params)
|
52
52
|
end
|
53
53
|
|
54
54
|
def apply(mode, template, node, **params)
|
55
|
-
handler_by(node.name).apply(mode, template, node, params)
|
55
|
+
handler_by(node.name).apply(mode, template, node, **params)
|
56
56
|
end
|
57
57
|
|
58
58
|
protected
|
data/lib/bemer/railtie.rb
CHANGED
@@ -9,10 +9,7 @@ module Bemer
|
|
9
9
|
class Railtie < ::Rails::Railtie
|
10
10
|
class << self
|
11
11
|
def assets_path_initializer
|
12
|
-
|
13
|
-
when 5..6 then :append_assets_path
|
14
|
-
when 3..4 then :load_config_initializers
|
15
|
-
end
|
12
|
+
::Rails::VERSION::MAJOR < 5 ? :load_config_initializers : :append_assets_path
|
16
13
|
end
|
17
14
|
end
|
18
15
|
|
data/lib/bemer/tag.rb
CHANGED
@@ -8,7 +8,7 @@ module Bemer
|
|
8
8
|
|
9
9
|
def initialize(block = '', element = nil, **options, &content)
|
10
10
|
@bem_cascade = options[:bem_cascade]
|
11
|
-
@tag_builder = TagBuilder.new(block, element, options, &content)
|
11
|
+
@tag_builder = TagBuilder.new(block, element, **options, &content)
|
12
12
|
@renderer = Renderer.new
|
13
13
|
end
|
14
14
|
|
data/lib/bemer/template_list.rb
CHANGED
data/lib/bemer/tree/base_node.rb
CHANGED
@@ -13,8 +13,8 @@ module Bemer
|
|
13
13
|
:content, :elem, :elem?, :element?, :js, :mix, :mods, :name, :tag
|
14
14
|
|
15
15
|
def initialize(tree, block = '', element = nil, **options, &content)
|
16
|
-
@entity = Entity.new(block, element, options, &content)
|
17
|
-
@entity_builder = EntityBuilder.new(block, element, options, &content)
|
16
|
+
@entity = Entity.new(block, element, **options, &content)
|
17
|
+
@entity_builder = EntityBuilder.new(block, element, **options, &content)
|
18
18
|
@renderer = Renderer.new
|
19
19
|
@tree = tree
|
20
20
|
end
|
data/lib/bemer/tree/node.rb
CHANGED
@@ -12,7 +12,7 @@ module Bemer
|
|
12
12
|
alias need_replace? need_replace
|
13
13
|
|
14
14
|
def initialize(tree, block = '', element = nil, **options, &content)
|
15
|
-
super(tree, block, element, options, &content)
|
15
|
+
super(tree, block, element, **options, &content)
|
16
16
|
|
17
17
|
@applied_modes = Pipeline::MODES.map { |mode| [mode, false] }.to_h
|
18
18
|
@children = []
|
@@ -62,11 +62,11 @@ module Bemer
|
|
62
62
|
end
|
63
63
|
|
64
64
|
def apply_next(template, **params)
|
65
|
-
tree.pipeline.apply_next(template, self, params)
|
65
|
+
tree.pipeline.apply_next(template, self, **params)
|
66
66
|
end
|
67
67
|
|
68
68
|
def apply(mode, template, **params)
|
69
|
-
tree.pipeline.apply(mode, template, self, params)
|
69
|
+
tree.pipeline.apply(mode, template, self, **params)
|
70
70
|
end
|
71
71
|
|
72
72
|
protected
|
data/lib/bemer/tree.rb
CHANGED
@@ -66,7 +66,7 @@ module Bemer
|
|
66
66
|
bem_cascade = inherited_bem_cascade if bem_cascade.nil?
|
67
67
|
new_options = { **params, bem_cascade: bem_cascade, **options }
|
68
68
|
|
69
|
-
add Node.new(self, block, element, new_options, &content)
|
69
|
+
add Node.new(self, block, element, **new_options, &content)
|
70
70
|
end
|
71
71
|
|
72
72
|
def add_text_node(content = nil, &callback)
|
data/lib/bemer/version.rb
CHANGED
data/spec/bemer/railtie_spec.rb
CHANGED
@@ -38,7 +38,7 @@ RSpec.describe Bemer::Railtie do
|
|
38
38
|
describe 'bemer.helpers initializer' do
|
39
39
|
subject(:initializer) { find_initializer('bemer.helpers') }
|
40
40
|
|
41
|
-
let(:action_view) { ActionView::Base.new }
|
41
|
+
let(:action_view) { ActionView::Base.respond_to?(:empty) ? ActionView::Base.empty : ActionView::Base.new }
|
42
42
|
|
43
43
|
helper_methods = %i[
|
44
44
|
block_tag elem_tag bem_mix bem_mods render_component
|
metadata
CHANGED
@@ -1,197 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bemer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Grigorev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-05-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
-
- !ruby/object:Gem::Dependency
|
14
|
-
name: appraisal
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - "~>"
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: 2.2.0
|
20
|
-
type: :development
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - "~>"
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: 2.2.0
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: bundler-audit
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - "~>"
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 0.6.1
|
34
|
-
type: :development
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - "~>"
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: 0.6.1
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: fasterer
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: 0.7.1
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: 0.7.1
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: fuubar
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
58
|
-
requirements:
|
59
|
-
- - "~>"
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
version: 2.5.0
|
62
|
-
type: :development
|
63
|
-
prerelease: false
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
65
|
-
requirements:
|
66
|
-
- - "~>"
|
67
|
-
- !ruby/object:Gem::Version
|
68
|
-
version: 2.5.0
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: overcommit
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
72
|
-
requirements:
|
73
|
-
- - "~>"
|
74
|
-
- !ruby/object:Gem::Version
|
75
|
-
version: 0.47.0
|
76
|
-
type: :development
|
77
|
-
prerelease: false
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
79
|
-
requirements:
|
80
|
-
- - "~>"
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: 0.47.0
|
83
|
-
- !ruby/object:Gem::Dependency
|
84
|
-
name: rake
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
86
|
-
requirements:
|
87
|
-
- - "~>"
|
88
|
-
- !ruby/object:Gem::Version
|
89
|
-
version: 12.3.3
|
90
|
-
type: :development
|
91
|
-
prerelease: false
|
92
|
-
version_requirements: !ruby/object:Gem::Requirement
|
93
|
-
requirements:
|
94
|
-
- - "~>"
|
95
|
-
- !ruby/object:Gem::Version
|
96
|
-
version: 12.3.3
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: rspec
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - "~>"
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: 3.9.0
|
104
|
-
type: :development
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - "~>"
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: 3.9.0
|
111
|
-
- !ruby/object:Gem::Dependency
|
112
|
-
name: rspec-html-matchers
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
114
|
-
requirements:
|
115
|
-
- - "~>"
|
116
|
-
- !ruby/object:Gem::Version
|
117
|
-
version: 0.9.2
|
118
|
-
type: :development
|
119
|
-
prerelease: false
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
requirements:
|
122
|
-
- - "~>"
|
123
|
-
- !ruby/object:Gem::Version
|
124
|
-
version: 0.9.2
|
125
|
-
- !ruby/object:Gem::Dependency
|
126
|
-
name: rspec-rails
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
128
|
-
requirements:
|
129
|
-
- - "~>"
|
130
|
-
- !ruby/object:Gem::Version
|
131
|
-
version: 3.9.0
|
132
|
-
type: :development
|
133
|
-
prerelease: false
|
134
|
-
version_requirements: !ruby/object:Gem::Requirement
|
135
|
-
requirements:
|
136
|
-
- - "~>"
|
137
|
-
- !ruby/object:Gem::Version
|
138
|
-
version: 3.9.0
|
139
|
-
- !ruby/object:Gem::Dependency
|
140
|
-
name: rubocop
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
142
|
-
requirements:
|
143
|
-
- - "~>"
|
144
|
-
- !ruby/object:Gem::Version
|
145
|
-
version: 0.68.1
|
146
|
-
type: :development
|
147
|
-
prerelease: false
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
149
|
-
requirements:
|
150
|
-
- - "~>"
|
151
|
-
- !ruby/object:Gem::Version
|
152
|
-
version: 0.68.1
|
153
|
-
- !ruby/object:Gem::Dependency
|
154
|
-
name: rubocop-performance
|
155
|
-
requirement: !ruby/object:Gem::Requirement
|
156
|
-
requirements:
|
157
|
-
- - "~>"
|
158
|
-
- !ruby/object:Gem::Version
|
159
|
-
version: 1.3.0
|
160
|
-
type: :development
|
161
|
-
prerelease: false
|
162
|
-
version_requirements: !ruby/object:Gem::Requirement
|
163
|
-
requirements:
|
164
|
-
- - "~>"
|
165
|
-
- !ruby/object:Gem::Version
|
166
|
-
version: 1.3.0
|
167
|
-
- !ruby/object:Gem::Dependency
|
168
|
-
name: rubocop-rspec
|
169
|
-
requirement: !ruby/object:Gem::Requirement
|
170
|
-
requirements:
|
171
|
-
- - "~>"
|
172
|
-
- !ruby/object:Gem::Version
|
173
|
-
version: 1.38.1
|
174
|
-
type: :development
|
175
|
-
prerelease: false
|
176
|
-
version_requirements: !ruby/object:Gem::Requirement
|
177
|
-
requirements:
|
178
|
-
- - "~>"
|
179
|
-
- !ruby/object:Gem::Version
|
180
|
-
version: 1.38.1
|
181
|
-
- !ruby/object:Gem::Dependency
|
182
|
-
name: wwtd
|
183
|
-
requirement: !ruby/object:Gem::Requirement
|
184
|
-
requirements:
|
185
|
-
- - "~>"
|
186
|
-
- !ruby/object:Gem::Version
|
187
|
-
version: 1.4.0
|
188
|
-
type: :development
|
189
|
-
prerelease: false
|
190
|
-
version_requirements: !ruby/object:Gem::Requirement
|
191
|
-
requirements:
|
192
|
-
- - "~>"
|
193
|
-
- !ruby/object:Gem::Version
|
194
|
-
version: 1.4.0
|
195
13
|
- !ruby/object:Gem::Dependency
|
196
14
|
name: railties
|
197
15
|
requirement: !ruby/object:Gem::Requirement
|
@@ -342,7 +160,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
342
160
|
- !ruby/object:Gem::Version
|
343
161
|
version: 2.2.0
|
344
162
|
requirements: []
|
345
|
-
rubygems_version: 3.
|
163
|
+
rubygems_version: 3.4.12
|
346
164
|
signing_key:
|
347
165
|
specification_version: 4
|
348
166
|
summary: Build reusable UI components for Rails applications with the ability to use
|