lookbook 1.0.5 → 1.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lookbook/config.rb +1 -1
- data/lib/lookbook/engine.rb +8 -10
- data/lib/lookbook/version.rb +1 -1
- data/public/lookbook-assets/js/lookbook.js +75 -75
- data/public/lookbook-assets/js/lookbook.js.map +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2985b373024d4f48a503252274dc0606cfbb062ea2d229163c62980f9ff492b7
|
4
|
+
data.tar.gz: 60352ee8d3599fe86b8fe7dc068f391913ed4727bf2b500f605fe8b49ad7dbc0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f962058591eba3fd20629d4cff57515f4931b754091af6112ddcca16a911945640dbc556031edcfb34b780aa7f0690c40d32a811077ff0bb91c3f42f143ff8e2
|
7
|
+
data.tar.gz: b5d4d2d49675b4389bc1bb4814559eaf01e4445e0c2623a796a8a82d27ccdfeacd742837e3022c027fd2d5b22bb02a99b0720a321f6b9151145fd3f16266cbd4
|
data/lib/lookbook/config.rb
CHANGED
data/lib/lookbook/engine.rb
CHANGED
@@ -127,12 +127,11 @@ module Lookbook
|
|
127
127
|
return unless config.listen == true
|
128
128
|
Listen.logger = Lookbook.logger
|
129
129
|
|
130
|
-
|
131
|
-
|
132
|
-
|
130
|
+
listen_paths = config.listen_paths.uniq
|
131
|
+
if listen_paths.any?
|
132
|
+
preview_listener = Listen.to(*listen_paths,
|
133
133
|
only: /\.(#{config.listen_extensions.join("|")})$/,
|
134
|
-
force_polling: config.listen_use_polling
|
135
|
-
) do |modified, added, removed|
|
134
|
+
force_polling: config.listen_use_polling) do |modified, added, removed|
|
136
135
|
parser.parse do
|
137
136
|
run_hooks(:after_change, {modified: modified, added: added, removed: removed})
|
138
137
|
end
|
@@ -140,12 +139,11 @@ module Lookbook
|
|
140
139
|
register_listener(preview_listener)
|
141
140
|
end
|
142
141
|
|
143
|
-
|
144
|
-
|
145
|
-
|
142
|
+
page_paths = config.page_paths.uniq
|
143
|
+
if page_paths.any?
|
144
|
+
page_listener = Listen.to(*page_paths,
|
146
145
|
only: /\.(html.*|md.*)$/,
|
147
|
-
force_polling: config.listen_use_polling
|
148
|
-
) do |modified, added, removed|
|
146
|
+
force_polling: config.listen_use_polling) do |modified, added, removed|
|
149
147
|
changes = {modified: modified, added: added, removed: removed}
|
150
148
|
reload_ui
|
151
149
|
run_hooks(:after_change, changes)
|
data/lib/lookbook/version.rb
CHANGED
@@ -7755,7 +7755,7 @@ function $5439cede634b2921$var$toCamel(s) {
|
|
7755
7755
|
}
|
7756
7756
|
|
7757
7757
|
|
7758
|
-
var $
|
7758
|
+
var $4dba57edf150b96d$exports = {};
|
7759
7759
|
var $cbd28b10fa9798c7$exports = {};
|
7760
7760
|
|
7761
7761
|
$parcel$defineInteropFlag($cbd28b10fa9798c7$exports);
|
@@ -13018,33 +13018,6 @@ function $506dabb2bf255b38$var$sizeSplits(sizes) {
|
|
13018
13018
|
}
|
13019
13019
|
|
13020
13020
|
|
13021
|
-
var $a87dacf5139b5e2f$exports = {};
|
13022
|
-
|
13023
|
-
$parcel$defineInteropFlag($a87dacf5139b5e2f$exports);
|
13024
|
-
|
13025
|
-
$parcel$export($a87dacf5139b5e2f$exports, "default", () => $a87dacf5139b5e2f$export$2e2bcd8739ae039);
|
13026
|
-
function $a87dacf5139b5e2f$export$2e2bcd8739ae039(store) {
|
13027
|
-
return {
|
13028
|
-
get store () {
|
13029
|
-
return store || this;
|
13030
|
-
},
|
13031
|
-
get id () {
|
13032
|
-
return this.$root.id;
|
13033
|
-
},
|
13034
|
-
get panels () {
|
13035
|
-
return Array.from(this.$refs.panels.children);
|
13036
|
-
},
|
13037
|
-
isActive (el) {
|
13038
|
-
return this.store.activeTab === this._getRef(el);
|
13039
|
-
},
|
13040
|
-
// protected
|
13041
|
-
_getRef (el) {
|
13042
|
-
return el.getAttribute("x-ref");
|
13043
|
-
}
|
13044
|
-
};
|
13045
|
-
}
|
13046
|
-
|
13047
|
-
|
13048
13021
|
var $0db07828cadc68e0$exports = {};
|
13049
13022
|
|
13050
13023
|
$parcel$defineInteropFlag($0db07828cadc68e0$exports);
|
@@ -13137,6 +13110,33 @@ function $0db07828cadc68e0$export$2e2bcd8739ae039(store) {
|
|
13137
13110
|
}
|
13138
13111
|
|
13139
13112
|
|
13113
|
+
var $a87dacf5139b5e2f$exports = {};
|
13114
|
+
|
13115
|
+
$parcel$defineInteropFlag($a87dacf5139b5e2f$exports);
|
13116
|
+
|
13117
|
+
$parcel$export($a87dacf5139b5e2f$exports, "default", () => $a87dacf5139b5e2f$export$2e2bcd8739ae039);
|
13118
|
+
function $a87dacf5139b5e2f$export$2e2bcd8739ae039(store) {
|
13119
|
+
return {
|
13120
|
+
get store () {
|
13121
|
+
return store || this;
|
13122
|
+
},
|
13123
|
+
get id () {
|
13124
|
+
return this.$root.id;
|
13125
|
+
},
|
13126
|
+
get panels () {
|
13127
|
+
return Array.from(this.$refs.panels.children);
|
13128
|
+
},
|
13129
|
+
isActive (el) {
|
13130
|
+
return this.store.activeTab === this._getRef(el);
|
13131
|
+
},
|
13132
|
+
// protected
|
13133
|
+
_getRef (el) {
|
13134
|
+
return el.getAttribute("x-ref");
|
13135
|
+
}
|
13136
|
+
};
|
13137
|
+
}
|
13138
|
+
|
13139
|
+
|
13140
13140
|
var $6d64716f0b34fdf4$exports = {};
|
13141
13141
|
|
13142
13142
|
$parcel$defineInteropFlag($6d64716f0b34fdf4$exports);
|
@@ -13264,7 +13264,7 @@ function $6d64716f0b34fdf4$export$2e2bcd8739ae039(store) {
|
|
13264
13264
|
}
|
13265
13265
|
|
13266
13266
|
|
13267
|
-
$
|
13267
|
+
$4dba57edf150b96d$exports = {
|
13268
13268
|
"button": $cbd28b10fa9798c7$exports,
|
13269
13269
|
"code": $99486586f6691564$exports,
|
13270
13270
|
"copy_button": $47a1c62621be0c54$exports,
|
@@ -13275,51 +13275,13 @@ $730b795bb0498251$exports = {
|
|
13275
13275
|
"nav": $d92d9d5253f84566$exports,
|
13276
13276
|
"params_editor": $b63b9c6d236b3f65$exports,
|
13277
13277
|
"split_layout": $506dabb2bf255b38$exports,
|
13278
|
-
"tab_panels": $a87dacf5139b5e2f$exports,
|
13279
13278
|
"tabs": $0db07828cadc68e0$exports,
|
13279
|
+
"tab_panels": $a87dacf5139b5e2f$exports,
|
13280
13280
|
"viewport": $6d64716f0b34fdf4$exports
|
13281
13281
|
};
|
13282
13282
|
|
13283
13283
|
|
13284
|
-
var $
|
13285
|
-
var $fa8073e5be19dff9$exports = {};
|
13286
|
-
|
13287
|
-
$parcel$defineInteropFlag($fa8073e5be19dff9$exports);
|
13288
|
-
|
13289
|
-
$parcel$export($fa8073e5be19dff9$exports, "default", () => $fa8073e5be19dff9$export$2e2bcd8739ae039);
|
13290
|
-
function $fa8073e5be19dff9$export$2e2bcd8739ae039({ name: name , value: value }) {
|
13291
|
-
return {
|
13292
|
-
name: name,
|
13293
|
-
value: value,
|
13294
|
-
init () {
|
13295
|
-
this.$watch("value", ()=>this.update());
|
13296
|
-
},
|
13297
|
-
update () {
|
13298
|
-
if (this.validate()) {
|
13299
|
-
const searchParams = new URLSearchParams(window.location.search);
|
13300
|
-
searchParams.set(this.name, this.value);
|
13301
|
-
const path = location.href.replace(location.search, "");
|
13302
|
-
this.navigateTo(`${path}?${searchParams.toString()}`);
|
13303
|
-
}
|
13304
|
-
},
|
13305
|
-
validate () {
|
13306
|
-
return this.$root.reportValidity ? this.$root.reportValidity() : true;
|
13307
|
-
},
|
13308
|
-
get isNarrowLayout () {
|
13309
|
-
return this.narrow || false;
|
13310
|
-
},
|
13311
|
-
bindings: {
|
13312
|
-
input: {
|
13313
|
-
[":id"]: "`param-${name}`",
|
13314
|
-
["x-ref"]: "input",
|
13315
|
-
["x-model.debounce.200"]: "value",
|
13316
|
-
["@keydown.stop"]: true
|
13317
|
-
}
|
13318
|
-
}
|
13319
|
-
};
|
13320
|
-
}
|
13321
|
-
|
13322
|
-
|
13284
|
+
var $e4eab7529959b73b$exports = {};
|
13323
13285
|
var $9b24cbeb3a465447$exports = {};
|
13324
13286
|
|
13325
13287
|
$parcel$defineInteropFlag($9b24cbeb3a465447$exports);
|
@@ -13376,12 +13338,50 @@ function $9b24cbeb3a465447$export$2e2bcd8739ae039({ id: id , matchers: matchers
|
|
13376
13338
|
}
|
13377
13339
|
|
13378
13340
|
|
13379
|
-
$
|
13380
|
-
|
13381
|
-
|
13382
|
-
|
13341
|
+
var $fa8073e5be19dff9$exports = {};
|
13342
|
+
|
13343
|
+
$parcel$defineInteropFlag($fa8073e5be19dff9$exports);
|
13344
|
+
|
13345
|
+
$parcel$export($fa8073e5be19dff9$exports, "default", () => $fa8073e5be19dff9$export$2e2bcd8739ae039);
|
13346
|
+
function $fa8073e5be19dff9$export$2e2bcd8739ae039({ name: name , value: value }) {
|
13347
|
+
return {
|
13348
|
+
name: name,
|
13349
|
+
value: value,
|
13350
|
+
init () {
|
13351
|
+
this.$watch("value", ()=>this.update());
|
13352
|
+
},
|
13353
|
+
update () {
|
13354
|
+
if (this.validate()) {
|
13355
|
+
const searchParams = new URLSearchParams(window.location.search);
|
13356
|
+
searchParams.set(this.name, this.value);
|
13357
|
+
const path = location.href.replace(location.search, "");
|
13358
|
+
this.navigateTo(`${path}?${searchParams.toString()}`);
|
13359
|
+
}
|
13360
|
+
},
|
13361
|
+
validate () {
|
13362
|
+
return this.$root.reportValidity ? this.$root.reportValidity() : true;
|
13363
|
+
},
|
13364
|
+
get isNarrowLayout () {
|
13365
|
+
return this.narrow || false;
|
13366
|
+
},
|
13367
|
+
bindings: {
|
13368
|
+
input: {
|
13369
|
+
[":id"]: "`param-${name}`",
|
13370
|
+
["x-ref"]: "input",
|
13371
|
+
["x-model.debounce.200"]: "value",
|
13372
|
+
["@keydown.stop"]: true
|
13373
|
+
}
|
13374
|
+
}
|
13375
|
+
};
|
13376
|
+
}
|
13377
|
+
|
13378
|
+
|
13379
|
+
$e4eab7529959b73b$exports = {
|
13383
13380
|
"nav": {
|
13384
13381
|
"item": $9b24cbeb3a465447$exports
|
13382
|
+
},
|
13383
|
+
"params_editor": {
|
13384
|
+
"field": $fa8073e5be19dff9$exports
|
13385
13385
|
}
|
13386
13386
|
};
|
13387
13387
|
|
@@ -13421,8 +13421,8 @@ const $d73574cc5e9b9e72$var$prefix = window.APP_NAME;
|
|
13421
13421
|
// Components
|
13422
13422
|
(0, $caa9439642c6336c$export$2e2bcd8739ae039).data("app", (0, $d709d0f4027033b2$export$2e2bcd8739ae039));
|
13423
13423
|
[
|
13424
|
-
$
|
13425
|
-
$
|
13424
|
+
$4dba57edf150b96d$exports,
|
13425
|
+
$e4eab7529959b73b$exports,
|
13426
13426
|
$4979d2d897a1c01f$exports
|
13427
13427
|
].forEach((scripts)=>{
|
13428
13428
|
const components1 = (0, $5439cede634b2921$export$4e811121b221213b)(scripts);
|