matestack-ui-bootstrap 2.1.0 → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/matestack/ui/bootstrap/base_component.rb +0 -2
- data/lib/matestack/ui/bootstrap/base_vue_js_component.rb +1 -3
- data/lib/matestack/ui/bootstrap/components/alert.js +14 -12
- data/lib/matestack/ui/bootstrap/components/carousel.js +17 -15
- data/lib/matestack/ui/bootstrap/components/collapse.js +18 -16
- data/lib/matestack/ui/bootstrap/components/dropdown.js +7 -5
- data/lib/matestack/ui/bootstrap/components/modal.js +12 -11
- data/lib/matestack/ui/bootstrap/components/navbar.rb +3 -3
- data/lib/matestack/ui/bootstrap/components/popover.js +10 -9
- data/lib/matestack/ui/bootstrap/components/toast.js +19 -18
- data/lib/matestack/ui/bootstrap/components/toast.rb +3 -3
- data/lib/matestack/ui/bootstrap/components/tooltip.js +9 -9
- data/lib/matestack/ui/bootstrap/form/checkbox.rb +1 -3
- data/lib/matestack/ui/bootstrap/form/input.rb +0 -2
- data/lib/matestack/ui/bootstrap/form/radio.rb +0 -2
- data/lib/matestack/ui/bootstrap/form/select.rb +0 -2
- data/lib/matestack/ui/bootstrap/form/submit.rb +2 -2
- data/lib/matestack/ui/bootstrap/form/switch.rb +0 -2
- data/lib/matestack/ui/bootstrap/form/textarea.rb +0 -2
- data/lib/matestack/ui/bootstrap/index.js +26 -10
- data/lib/matestack/ui/bootstrap/initialize.rb +3 -0
- data/lib/matestack/ui/bootstrap/layout/sidebar.js +9 -8
- data/lib/matestack/ui/bootstrap/layout/sidebar.rb +10 -12
- data/lib/matestack/ui/bootstrap/{apps → layouts}/admin_template.rb +9 -11
- data/lib/matestack/ui/bootstrap/version.rb +1 -1
- data/lib/matestack/ui/bootstrap.rb +4 -2
- metadata +21 -12
- data/config/webpack/development.js +0 -5
- data/config/webpack/environment.js +0 -29
- data/config/webpack/production.js +0 -33
- data/config/webpack/test.js +0 -5
- data/config/webpacker.yml +0 -96
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b38c029b0abf064a716c915e47f1b0b433a65ccf70b6b9713d35193b21636705
|
4
|
+
data.tar.gz: ab3c390b4030c118702f0d7dfa60dc13436a43f8fd282a0d25d4d71225fcdbb3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5f5d39b474c3658d2afff912b73d5860e340e5b3d913459dc555f2762130a0d12549b485dc595c7de8d6be23a76a31e85b4eb4f1dd1f50e8592d18ccdf092646
|
7
|
+
data.tar.gz: e3f2c4278d9842cef53ac97571fe956413beb6abb9f3fc0f94b8f28eefcae42cf5ffdee455446349e9695ea0557fbce58293d659a631c101cf264be2e0327e7b
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
mixins: [
|
5
|
+
const alertComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
8
|
|
9
9
|
data() {
|
10
10
|
return {
|
@@ -18,13 +18,13 @@ Vue.component('matestack-ui-bootstrap-alert', {
|
|
18
18
|
},
|
19
19
|
dispose: function (){
|
20
20
|
this.alertInstance.dispose()
|
21
|
-
// this.alertInstance = new bootstrap.Alert(self
|
21
|
+
// this.alertInstance = new bootstrap.Alert(self.getElement())
|
22
22
|
}
|
23
23
|
},
|
24
24
|
|
25
25
|
mounted: function() {
|
26
26
|
const self = this
|
27
|
-
var alert = self
|
27
|
+
var alert = self.getElement()
|
28
28
|
self.alertInstance = new bootstrap.Alert(alert)
|
29
29
|
},
|
30
30
|
|
@@ -33,24 +33,26 @@ Vue.component('matestack-ui-bootstrap-alert', {
|
|
33
33
|
// close_on event registration
|
34
34
|
if(self.props["close_on"] != undefined){
|
35
35
|
var close_events = self.props["close_on"].split(",")
|
36
|
-
close_events.forEach(close_event =>
|
36
|
+
close_events.forEach(close_event => MatestackUiVueJs.eventHub.$on(close_event.trim(), self.close));
|
37
37
|
}
|
38
38
|
// dispose_on event registration
|
39
39
|
if(self.props["dispose_on"] != undefined){
|
40
40
|
var dispose_events = self.props["dispose_on"].split(",")
|
41
|
-
dispose_events.forEach(dispose_event =>
|
41
|
+
dispose_events.forEach(dispose_event => MatestackUiVueJs.eventHub.$on(dispose_event.trim(), self.dispose));
|
42
42
|
}
|
43
43
|
},
|
44
44
|
|
45
|
-
|
45
|
+
beforeUnmount: function() {
|
46
46
|
const self = this
|
47
47
|
if(self.props["close_on"] != undefined){
|
48
48
|
var closen_events = self.props["close_on"].split(",")
|
49
|
-
closen_events.forEach(close_event =>
|
49
|
+
closen_events.forEach(close_event => MatestackUiVueJs.eventHub.$off(close_event.trim(), self.close));
|
50
50
|
}
|
51
51
|
if(self.props["dispose_on"] != undefined){
|
52
52
|
var dispose_events = self.props["dispose_on"].split(",")
|
53
|
-
dispose_events.forEach(dispose_event =>
|
53
|
+
dispose_events.forEach(dispose_event => MatestackUiVueJs.eventHub.$off(dispose_event.trim(), self.dispose));
|
54
54
|
}
|
55
55
|
},
|
56
|
-
}
|
56
|
+
}
|
57
|
+
|
58
|
+
export default alertComponent
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
mixins: [
|
5
|
+
const carouselComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
8
|
data() {
|
9
9
|
return {
|
10
10
|
carouselInstance: undefined
|
@@ -32,7 +32,7 @@ Vue.component('matestack-ui-bootstrap-carousel', {
|
|
32
32
|
|
33
33
|
mounted: function() {
|
34
34
|
const self = this;
|
35
|
-
var myCarousel = self
|
35
|
+
var myCarousel = self.getElement();
|
36
36
|
self.carouselInstance = new bootstrap.Carousel(myCarousel, {
|
37
37
|
interval: (self.props['interval'] || 5000)
|
38
38
|
})
|
@@ -42,41 +42,43 @@ Vue.component('matestack-ui-bootstrap-carousel', {
|
|
42
42
|
const self = this
|
43
43
|
if(self.props["cycle_on"] != undefined){
|
44
44
|
var cycle_events = self.props["cycle_on"].split(",")
|
45
|
-
cycle_events.forEach(cycle_event =>
|
45
|
+
cycle_events.forEach(cycle_event => MatestackUiVueJs.eventHub.$on(cycle_event.trim(), self.cycle));
|
46
46
|
}
|
47
47
|
if(self.props["pause_on"] != undefined){
|
48
48
|
var pause_events = self.props["pause_on"].split(",")
|
49
|
-
pause_events.forEach(pause_event =>
|
49
|
+
pause_events.forEach(pause_event => MatestackUiVueJs.eventHub.$on(pause_event.trim(), self.pause));
|
50
50
|
}
|
51
51
|
if(self.props["prev_on"] != undefined){
|
52
52
|
var prev_events = self.props["prev_on"].split(",")
|
53
|
-
prev_events.forEach(prev_event =>
|
53
|
+
prev_events.forEach(prev_event => MatestackUiVueJs.eventHub.$on(prev_event.trim(), self.prev));
|
54
54
|
}
|
55
55
|
if(self.props["next_on"] != undefined){
|
56
56
|
var next_events = self.props["next_on"].split(",")
|
57
|
-
next_events.forEach(next_event =>
|
57
|
+
next_events.forEach(next_event => MatestackUiVueJs.eventHub.$on(next_event.trim(), self.next));
|
58
58
|
}
|
59
59
|
},
|
60
60
|
|
61
|
-
|
61
|
+
beforeUnmount: function() {
|
62
62
|
const self = this
|
63
63
|
if(self.props["cycle_on"] != undefined){
|
64
64
|
var cycle_events = self.props["cycle_on"].split(",")
|
65
|
-
cycle_events.forEach(cycle_event =>
|
65
|
+
cycle_events.forEach(cycle_event => MatestackUiVueJs.eventHub.$off(cycle_event.trim(), self.cycle));
|
66
66
|
}
|
67
67
|
|
68
68
|
if(self.props["pause_on"] != undefined){
|
69
69
|
var pause_events = self.props["pause_on"].split(",")
|
70
|
-
pause_events.forEach(pause_event =>
|
70
|
+
pause_events.forEach(pause_event => MatestackUiVueJs.eventHub.$off(pause_event.trim(), self.pause));
|
71
71
|
}
|
72
72
|
|
73
73
|
if(self.props["prev_on"] != undefined){
|
74
74
|
var prev_events = self.props["prev_on"].split(",")
|
75
|
-
prev_events.forEach(prev_event =>
|
75
|
+
prev_events.forEach(prev_event => MatestackUiVueJs.eventHub.$off(prev_event.trim(), self.prev));
|
76
76
|
}
|
77
77
|
if(self.props["next_on"] != undefined){
|
78
78
|
var next_events = self.props["next_on"].split(",")
|
79
|
-
next_events.forEach(next_event =>
|
79
|
+
next_events.forEach(next_event => MatestackUiVueJs.eventHub.$off(next_event.trim(), self.next));
|
80
80
|
}
|
81
81
|
},
|
82
|
-
}
|
82
|
+
}
|
83
|
+
|
84
|
+
export default carouselComponent
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
mixins: [
|
5
|
+
const collapseComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
8
|
data() {
|
9
9
|
return {
|
10
10
|
collapseInstance: undefined
|
@@ -34,8 +34,8 @@ Vue.component('matestack-ui-bootstrap-collapse', {
|
|
34
34
|
|
35
35
|
mounted: function() {
|
36
36
|
const self = this;
|
37
|
-
|
38
|
-
self.collapseInstance = new bootstrap.Collapse(
|
37
|
+
const collapseElement = self.getElement()
|
38
|
+
self.collapseInstance = new bootstrap.Collapse(collapseElement, {
|
39
39
|
toggle: false
|
40
40
|
})
|
41
41
|
},
|
@@ -46,42 +46,44 @@ Vue.component('matestack-ui-bootstrap-collapse', {
|
|
46
46
|
// toggle_on event registration
|
47
47
|
if(self.props["toggle_on"] != undefined){
|
48
48
|
var toggle_events = self.props["toggle_on"].split(",")
|
49
|
-
toggle_events.forEach(toggle_event =>
|
49
|
+
toggle_events.forEach(toggle_event => MatestackUiVueJs.eventHub.$on(toggle_event.trim(), self.toggle));
|
50
50
|
}
|
51
51
|
// show_on event registration
|
52
52
|
if(self.props["show_on"] != undefined){
|
53
53
|
var show_events = self.props["show_on"].split(",")
|
54
|
-
show_events.forEach(show_event =>
|
54
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$on(show_event.trim(), self.show));
|
55
55
|
}
|
56
56
|
// hide_on event registration
|
57
57
|
if(self.props["hide_on"] != undefined){
|
58
58
|
var hide_events = self.props["hide_on"].split(",")
|
59
|
-
hide_events.forEach(hide_event =>
|
59
|
+
hide_events.forEach(hide_event => MatestackUiVueJs.eventHub.$on(hide_event.trim(), self.hide));
|
60
60
|
}
|
61
61
|
// dispose_on event registration
|
62
62
|
if(self.props["dispose_on"] != undefined){
|
63
63
|
var dispose_events = self.props["dispose_on"].split(",")
|
64
|
-
dispose_events.forEach(dispose_event =>
|
64
|
+
dispose_events.forEach(dispose_event => MatestackUiVueJs.eventHub.$on(dispose_event.trim(), self.dispose));
|
65
65
|
}
|
66
66
|
},
|
67
67
|
|
68
|
-
|
68
|
+
beforeUnmount: function(){
|
69
69
|
const self = this
|
70
70
|
if(self.props["toggle_on"] != undefined){
|
71
71
|
var show_events = self.props["toggle_on"].split(",")
|
72
|
-
show_events.forEach(show_event =>
|
72
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$off(show_event.trim(), self.show));
|
73
73
|
}
|
74
74
|
if(self.props["show_on"] != undefined){
|
75
75
|
var show_events = self.props["show_on"].split(",")
|
76
|
-
show_events.forEach(show_event =>
|
76
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$off(show_event.trim(), self.show));
|
77
77
|
}
|
78
78
|
if(self.props["hide_on"] != undefined){
|
79
79
|
var hide_events = self.props["hide_on"].split(",")
|
80
|
-
hide_events.forEach(hide_event =>
|
80
|
+
hide_events.forEach(hide_event => MatestackUiVueJs.eventHub.$off(hide_event.trim(), self.hide));
|
81
81
|
}
|
82
82
|
if(self.props["dispose_on"] != undefined){
|
83
83
|
var dispose_events = self.props["dispose_on"].split(",")
|
84
|
-
dispose_events.forEach(dispose_event =>
|
84
|
+
dispose_events.forEach(dispose_event => MatestackUiVueJs.eventHub.$off(dispose_event.trim(), self.dispose));
|
85
85
|
}
|
86
86
|
}
|
87
|
-
}
|
87
|
+
}
|
88
|
+
|
89
|
+
export default collapseComponent
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
mixins: [
|
5
|
+
const dropdownComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
8
|
data() {
|
9
9
|
return {
|
10
10
|
dropdownInstance: undefined
|
@@ -14,4 +14,6 @@ Vue.component('matestack-ui-bootstrap-dropdown', {
|
|
14
14
|
// var mydropdown = document.getElementById(this.props["dropdown-id"])
|
15
15
|
// this.dropdownInstance = new bootstrap.Dropdown(mydropdown)
|
16
16
|
}
|
17
|
-
}
|
17
|
+
}
|
18
|
+
|
19
|
+
export default dropdownComponent
|
@@ -1,10 +1,9 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import
|
2
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
mixins: [MatestackUiCore.componentMixin],
|
4
|
+
const modalComponent = {
|
5
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
6
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
7
|
|
9
8
|
data() {
|
10
9
|
return {
|
@@ -32,13 +31,13 @@ Vue.component('matestack-ui-bootstrap-modal', {
|
|
32
31
|
|
33
32
|
mounted: function() {
|
34
33
|
const self = this
|
35
|
-
|
36
|
-
self.modalInstance = new bootstrap.Modal(
|
34
|
+
const modalElement = self.getElement()
|
35
|
+
self.modalInstance = new bootstrap.Modal(modalElement)
|
37
36
|
},
|
38
37
|
|
39
38
|
created: function() {
|
40
39
|
const self = this
|
41
|
-
var eventHub =
|
40
|
+
var eventHub = MatestackUiVueJs.eventHub;
|
42
41
|
// toggle_on event registration
|
43
42
|
if(self.props["toggle_on"] != undefined){
|
44
43
|
var toggle_events = self.props["toggle_on"].split(",")
|
@@ -66,9 +65,9 @@ Vue.component('matestack-ui-bootstrap-modal', {
|
|
66
65
|
}
|
67
66
|
},
|
68
67
|
|
69
|
-
|
68
|
+
beforeUnmount: function() {
|
70
69
|
const self = this
|
71
|
-
var eventHub =
|
70
|
+
var eventHub = MatestackUiVueJs.eventHub;
|
72
71
|
if(self.props["toggle_on"] != undefined){
|
73
72
|
var toggle_events = self.props["toggle_on"].split(",")
|
74
73
|
toggle_events.forEach(toggle_event => eventHub.$off(toggle_event.trim(), self.toggle));
|
@@ -90,4 +89,6 @@ Vue.component('matestack-ui-bootstrap-modal', {
|
|
90
89
|
dispose_events.forEach(dispose_event => eventHub.$off(dispose_event.trim(), self.dispose));
|
91
90
|
}
|
92
91
|
},
|
93
|
-
}
|
92
|
+
}
|
93
|
+
|
94
|
+
export default modalComponent
|
@@ -42,13 +42,13 @@ class Matestack::Ui::Bootstrap::Components::Navbar < Matestack::Ui::Bootstrap::B
|
|
42
42
|
path = brand[:path].present? ? brand[:path] : "/"
|
43
43
|
brand[:path] = path
|
44
44
|
case brand[:type]
|
45
|
-
when :
|
46
|
-
|
45
|
+
when :transition
|
46
|
+
transition brand.except(:text).merge(class: "navbar-brand") do
|
47
47
|
img height: 40, path: brand[:img], loading: "lazy" if brand[:img].present?
|
48
48
|
plain brand[:text]
|
49
49
|
end
|
50
50
|
else
|
51
|
-
|
51
|
+
a brand.except(:text).merge(class: "navbar-brand") do
|
52
52
|
img height: 40, path: brand[:img], loading: "lazy" if brand[:img].present?
|
53
53
|
plain brand[:text]
|
54
54
|
end
|
@@ -1,11 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
|
8
|
-
|
5
|
+
const popoverComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
9
8
|
data() {
|
10
9
|
return {
|
11
10
|
popoverInstance: undefined
|
@@ -17,13 +16,15 @@ Vue.component('matestack-ui-bootstrap-popover', {
|
|
17
16
|
},
|
18
17
|
mounted: function() {
|
19
18
|
const self = this;
|
20
|
-
|
21
|
-
self.popoverInstance = new bootstrap.Popover(
|
19
|
+
const popoverElement = self.getElement()
|
20
|
+
self.popoverInstance = new bootstrap.Popover(popoverElement, {})
|
22
21
|
},
|
23
22
|
created: function() {
|
24
23
|
},
|
25
24
|
|
26
|
-
|
25
|
+
beforeUnmount: function() {
|
27
26
|
|
28
27
|
},
|
29
|
-
}
|
28
|
+
}
|
29
|
+
|
30
|
+
export default popoverComponent
|
@@ -1,11 +1,10 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import Vue from 'vue/dist/vue.esm'
|
3
2
|
|
4
|
-
import
|
3
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
5
4
|
|
6
|
-
|
7
|
-
|
8
|
-
|
5
|
+
const toastComponent = {
|
6
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
7
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
9
8
|
data() {
|
10
9
|
return {
|
11
10
|
toastsInstance: undefined,
|
@@ -40,12 +39,12 @@ Vue.component('matestack-ui-bootstrap-toast', {
|
|
40
39
|
dispose: function(){
|
41
40
|
const self = this;
|
42
41
|
self.toastsInstance.dispose()
|
43
|
-
self.toastsInstance = new bootstrap.Toast(self
|
42
|
+
self.toastsInstance = new bootstrap.Toast(self.getElement())
|
44
43
|
}
|
45
44
|
},
|
46
45
|
mounted: function() {
|
47
46
|
const self = this;
|
48
|
-
var myToasts = self
|
47
|
+
var myToasts = self.getElement()
|
49
48
|
self.toastsInstance = new bootstrap.Toast(myToasts)
|
50
49
|
},
|
51
50
|
created: function() {
|
@@ -53,36 +52,38 @@ Vue.component('matestack-ui-bootstrap-toast', {
|
|
53
52
|
|
54
53
|
if(this.props["show_on"] != undefined){
|
55
54
|
var show_events = this.props["show_on"].split(",")
|
56
|
-
show_events.forEach(show_event =>
|
55
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$on(show_event.trim(), self.show));
|
57
56
|
}
|
58
57
|
|
59
58
|
if(this.props["hide_on"] != undefined){
|
60
59
|
var show_events = this.props["hide_on"].split(",")
|
61
|
-
show_events.forEach(show_event =>
|
60
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$on(show_event.trim(), self.hide));
|
62
61
|
}
|
63
62
|
|
64
63
|
if(this.props["dispose_on"] != undefined){
|
65
64
|
var show_events = this.props["dispose_on"].split(",")
|
66
|
-
show_events.forEach(show_event =>
|
65
|
+
show_events.forEach(show_event => MatestackUiVueJs.eventHub.$on(show_event.trim(), self.dispose));
|
67
66
|
}
|
68
67
|
},
|
69
68
|
|
70
|
-
|
69
|
+
beforeUnmount: function() {
|
71
70
|
const self = this
|
72
|
-
|
73
|
-
|
74
|
-
|
71
|
+
MatestackUiVueJs.eventHub.$off(this.props["show_on"], self.show);
|
72
|
+
MatestackUiVueJs.eventHub.$off(this.props["hide_on"], self.hide);
|
73
|
+
MatestackUiVueJs.eventHub.$off(this.props["dispose_on"], self.hide);
|
75
74
|
if(this.props["show_on"] != undefined){
|
76
75
|
var shown_events = this.props["show_on"].split(",")
|
77
|
-
shown_events.forEach(show_event =>
|
76
|
+
shown_events.forEach(show_event => MatestackUiVueJs.eventHub.$off(show_event.trim(), self.show));
|
78
77
|
}
|
79
78
|
if(this.props["hide_on"] != undefined){
|
80
79
|
var hiden_events = this.props["hide_on"].split(",")
|
81
|
-
hiden_events.forEach(hide_event =>
|
80
|
+
hiden_events.forEach(hide_event => MatestackUiVueJs.eventHub.$off(hide_event.trim(), self.hide));
|
82
81
|
}
|
83
82
|
if(this.props["dispose_on"] != undefined){
|
84
83
|
var hiden_events = this.props["dispose_on"].split(",")
|
85
|
-
hiden_events.forEach(hide_event =>
|
84
|
+
hiden_events.forEach(hide_event => MatestackUiVueJs.eventHub.$off(hide_event.trim(), self.dispose));
|
86
85
|
}
|
87
86
|
},
|
88
|
-
}
|
87
|
+
}
|
88
|
+
|
89
|
+
export default toastComponent
|
@@ -56,7 +56,7 @@ class Matestack::Ui::Bootstrap::Components::Toast < Matestack::Ui::Bootstrap::Ba
|
|
56
56
|
small header[:subtitle] if header[:subtitle].present?
|
57
57
|
|
58
58
|
slot :header if slots && slots[:header]
|
59
|
-
bs_close dismiss: 'toast', class: "ms-2 mb-1", "@click": "hide()"
|
59
|
+
bs_close dismiss: 'toast', class: "ms-2 mb-1", "@click": "vc.hide()"
|
60
60
|
end
|
61
61
|
|
62
62
|
end
|
@@ -66,7 +66,7 @@ class Matestack::Ui::Bootstrap::Components::Toast < Matestack::Ui::Bootstrap::Ba
|
|
66
66
|
plain context.body if context.body
|
67
67
|
end
|
68
68
|
unless context.header || slots && slots[:header]
|
69
|
-
bs_close dismiss: 'toast', class: "ms-auto me-2 btn-close-white", "@click": "hide()"
|
69
|
+
bs_close dismiss: 'toast', class: "ms-auto me-2 btn-close-white", "@click": "vc.hide()"
|
70
70
|
end
|
71
71
|
end
|
72
72
|
|
@@ -92,7 +92,7 @@ class Matestack::Ui::Bootstrap::Components::Toast < Matestack::Ui::Bootstrap::Ba
|
|
92
92
|
hash[:'aria-live'] = 'assertive' unless context.important.present?
|
93
93
|
hash[:'aria-atomic'] = 'true' unless context.placement.present?
|
94
94
|
hash[:style] = "z-index: 10000; position: fixed; #{context.placement[:position] || 'top: 0; right: 0;' }" if context.placement.present?
|
95
|
-
hash[:"v-bind:class"] = "{'show' : showing }"
|
95
|
+
hash[:"v-bind:class"] = "{'show' : vc.showing }"
|
96
96
|
end
|
97
97
|
end
|
98
98
|
|
@@ -1,11 +1,9 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import
|
2
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
mixins: [MatestackUiCore.componentMixin],
|
4
|
+
const tooltipComponent = {
|
5
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
6
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
9
7
|
data() {
|
10
8
|
return {
|
11
9
|
// tooltipInstance: undefined
|
@@ -17,13 +15,15 @@ Vue.component('matestack-ui-bootstrap-tooltip', {
|
|
17
15
|
},
|
18
16
|
mounted: function() {
|
19
17
|
const self = this;
|
20
|
-
var tooltip = self
|
18
|
+
var tooltip = self.getElement()
|
21
19
|
self.tooltipInstance = new bootstrap.Tooltip(tooltip)
|
22
20
|
}
|
23
21
|
// created: function() {
|
24
22
|
// },
|
25
23
|
|
26
|
-
//
|
24
|
+
// beforeUnmount: function() {
|
27
25
|
|
28
26
|
// },
|
29
|
-
}
|
27
|
+
}
|
28
|
+
|
29
|
+
export default tooltipComponent
|
@@ -1,7 +1,5 @@
|
|
1
1
|
class Matestack::Ui::Bootstrap::Form::Checkbox < Matestack::Ui::VueJs::Components::Form::Checkbox
|
2
2
|
|
3
|
-
include Matestack::Ui::Bootstrap::Registry
|
4
|
-
|
5
3
|
vue_name "matestack-ui-core-form-checkbox"
|
6
4
|
|
7
5
|
optional :form_text
|
@@ -44,7 +42,7 @@ class Matestack::Ui::Bootstrap::Form::Checkbox < Matestack::Ui::VueJs::Component
|
|
44
42
|
# checked/unchecked checkbox (true/false checkbox)
|
45
43
|
else
|
46
44
|
checkbox_wrapper do
|
47
|
-
input true_false_checkbox_attributes.merge(type: :hidden, id: nil
|
45
|
+
input true_false_checkbox_attributes.merge(type: :hidden, id: nil)
|
48
46
|
input true_false_checkbox_attributes.merge(type: :checkbox, ":id": item_id(1)).merge(bootstrap_attributes)
|
49
47
|
|
50
48
|
bootstrap_label text: input_label, for_input: item_id(1)
|
@@ -8,10 +8,10 @@ class Matestack::Ui::Bootstrap::Form::Submit < Matestack::Ui::Bootstrap::BaseCom
|
|
8
8
|
optional class: { as: :bs_class }
|
9
9
|
|
10
10
|
def response
|
11
|
-
bs_btn type: "submit", size:context.size, class: "#{context.bs_class}", variant: context.button_variant || :primary, "v-if": "!loading" do
|
11
|
+
bs_btn type: "submit", size:context.size, class: "#{context.bs_class}", variant: context.button_variant || :primary, "v-if": "!vc.loading" do
|
12
12
|
plain context.text || "Submit"
|
13
13
|
end
|
14
|
-
bs_btn type: "submit", size: context.size, class: "#{context.bs_class} #{context.loading_class}", variant: context.button_variant || :primary, disabled: true, "v-if": "loading" do
|
14
|
+
bs_btn type: "submit", size: context.size, class: "#{context.bs_class} #{context.loading_class}", variant: context.button_variant || :primary, disabled: true, "v-if": "vc.loading" do
|
15
15
|
bs_spinner variant: context.spinner_variant || :light, size: :sm
|
16
16
|
plain context.loading_text || "Loading..."
|
17
17
|
end
|
@@ -5,19 +5,35 @@
|
|
5
5
|
|
6
6
|
import "./stylesheets/matestack-ui-bootstrap.scss";
|
7
7
|
|
8
|
-
import './components/alert'
|
9
|
-
import './components/carousel'
|
10
|
-
import './components/collapse'
|
11
|
-
import './components/dropdown'
|
12
|
-
import './components/modal'
|
13
|
-
import './components/
|
14
|
-
import './components/
|
15
|
-
import './components/tooltip'
|
16
|
-
import './layout/sidebar'
|
8
|
+
import alertComponent from './components/alert'
|
9
|
+
import carouselComponent from './components/carousel'
|
10
|
+
import collapseComponent from './components/collapse'
|
11
|
+
import dropdownComponent from './components/dropdown'
|
12
|
+
import modalComponent from './components/modal'
|
13
|
+
import popoverComponent from './components/popover'
|
14
|
+
import toastComponent from './components/toast'
|
15
|
+
import tooltipComponent from './components/tooltip'
|
16
|
+
import sidebarComponent from './layout/sidebar'
|
17
17
|
import './layout/sidebar.scss'
|
18
18
|
import './content/smart_collection/collection.scss'
|
19
19
|
|
20
|
-
const
|
20
|
+
const registerComponents = function(appInstance){
|
21
|
+
appInstance.component('matestack-ui-bootstrap-alert', alertComponent)
|
22
|
+
appInstance.component('matestack-ui-bootstrap-carousel', carouselComponent)
|
23
|
+
appInstance.component('matestack-ui-bootstrap-collapse', collapseComponent)
|
24
|
+
appInstance.component('matestack-ui-bootstrap-dropdown', dropdownComponent)
|
25
|
+
appInstance.component('matestack-ui-bootstrap-modal', modalComponent)
|
26
|
+
appInstance.component('matestack-ui-bootstrap-popover', popoverComponent)
|
27
|
+
appInstance.component('matestack-ui-bootstrap-toast', toastComponent)
|
28
|
+
appInstance.component('matestack-ui-bootstrap-tooltip', tooltipComponent)
|
29
|
+
appInstance.component('matestack-ui-bootstrap-sidebar', sidebarComponent)
|
30
|
+
|
31
|
+
return appInstance
|
32
|
+
}
|
33
|
+
|
34
|
+
const MatestackUiBootstrap = {
|
35
|
+
registerComponents
|
36
|
+
}
|
21
37
|
|
22
38
|
window.MatestackUiBootstrap = MatestackUiBootstrap
|
23
39
|
|
@@ -1,10 +1,9 @@
|
|
1
1
|
import * as bootstrap from 'bootstrap'
|
2
|
-
import
|
2
|
+
import MatestackUiVueJs from 'matestack-ui-vuejs'
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
mixins: [MatestackUiCore.componentMixin],
|
4
|
+
const sidebarComponent = {
|
5
|
+
mixins: [MatestackUiVueJs.componentMixin],
|
6
|
+
template: MatestackUiVueJs.componentHelpers.inlineTemplate,
|
8
7
|
|
9
8
|
data() {
|
10
9
|
return {
|
@@ -52,16 +51,18 @@ Vue.component('matestack-ui-bootstrap-sidebar', {
|
|
52
51
|
}
|
53
52
|
window.addEventListener('resize', this.resizeCallback);
|
54
53
|
var self = this;
|
55
|
-
|
54
|
+
MatestackUiVueJs.eventHub.$on("page_loaded", function(){
|
56
55
|
if (window.innerWidth <= 992){
|
57
56
|
self.closeSideBar();
|
58
57
|
}
|
59
58
|
})
|
60
|
-
|
59
|
+
MatestackUiVueJs.eventHub.$on("page_loading_triggered", function(){
|
61
60
|
if (window.innerWidth <= 992){
|
62
61
|
self.closeSideBar();
|
63
62
|
}
|
64
63
|
})
|
65
64
|
}
|
66
65
|
|
67
|
-
}
|
66
|
+
}
|
67
|
+
|
68
|
+
export default sidebarComponent
|
@@ -7,20 +7,18 @@ class Matestack::Ui::Bootstrap::Layout::Sidebar < Matestack::Ui::Bootstrap::Base
|
|
7
7
|
optional :sidebar_navigation_items
|
8
8
|
|
9
9
|
def response
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
bs_icon name: "list", size: 25, class: "text-muted"
|
15
|
-
end
|
16
|
-
end
|
17
|
-
div class: "sidebar-top mb-3" do
|
18
|
-
slot :sidebar_top if slots && slots[:sidebar_top].present?
|
19
|
-
end
|
20
|
-
div class: "sidebar-navigation my-3" do
|
21
|
-
sidebar_navigation_partial
|
10
|
+
nav class: 'sidebar pt-4 px-3 shadow-sm bg-white' do
|
11
|
+
div class: "sidebar-toggler" do
|
12
|
+
bs_btn variant: :link, "@click": "vc.sidebarToggle" do
|
13
|
+
bs_icon name: "list", size: 25, class: "text-muted"
|
22
14
|
end
|
23
15
|
end
|
16
|
+
div class: "sidebar-top mb-3" do
|
17
|
+
slot :sidebar_top if slots && slots[:sidebar_top].present?
|
18
|
+
end
|
19
|
+
div class: "sidebar-navigation my-3" do
|
20
|
+
sidebar_navigation_partial
|
21
|
+
end
|
24
22
|
end
|
25
23
|
end
|
26
24
|
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative "../registry"
|
2
2
|
|
3
|
-
class Matestack::Ui::Bootstrap::
|
4
|
-
|
5
|
-
include Matestack::Ui::Bootstrap::Registry
|
3
|
+
class Matestack::Ui::Bootstrap::Layouts::AdminTemplate < Matestack::Ui::Layout
|
6
4
|
|
7
5
|
def response(&block)
|
8
|
-
|
6
|
+
matestack_vue_js_app do
|
9
7
|
body_response(&block)
|
10
8
|
end
|
11
9
|
end
|
@@ -13,20 +11,20 @@ class Matestack::Ui::Bootstrap::Apps::AdminTemplate < Matestack::Ui::App
|
|
13
11
|
def body_response(&block)
|
14
12
|
div class: "d-flex flex-row" do
|
15
13
|
if should_show_sidebar?
|
16
|
-
|
14
|
+
div id: "sidebar", class: "sidebar-wrapper" do
|
15
|
+
bs_sidebar sidebar_navigation_items: sidebar_navigation_items, slots: { sidebar_top: method(:sidebar_top_slot) }
|
16
|
+
end
|
17
17
|
end
|
18
18
|
div id: "content", class: "content-wrapper w-100 #{content_background_class}" do
|
19
19
|
if should_show_navbar?
|
20
20
|
bs_container do
|
21
|
-
bs_navbar brand: navbar_brand_config, items: navbar_items, class: "pt-4 #{'ps-5' if should_show_sidebar?}", collapse_class: "text-end text-lg-start pe-3"
|
22
|
-
# div class: "d-flex" do
|
23
|
-
# navbar_end_partial if self.respond_to?(:navbar_end_partial)
|
24
|
-
# end
|
25
|
-
end
|
21
|
+
bs_navbar brand: navbar_brand_config, items: navbar_items, class: "pt-4 #{'ps-5' if should_show_sidebar?}", collapse_class: "text-end text-lg-start pe-3"
|
26
22
|
end
|
27
23
|
end
|
28
24
|
bs_container class: "my-5 px-4 pt-5" do
|
29
|
-
|
25
|
+
page_switch do
|
26
|
+
yield if block_given?
|
27
|
+
end
|
30
28
|
end
|
31
29
|
end
|
32
30
|
end
|
@@ -1,4 +1,5 @@
|
|
1
1
|
require "matestack/ui/core"
|
2
|
+
require "matestack/ui/vue_js"
|
2
3
|
|
3
4
|
base_path = 'matestack/ui/bootstrap'
|
4
5
|
require "#{base_path}/version"
|
@@ -16,12 +17,12 @@ require "#{base_path}/base_vue_js_component"
|
|
16
17
|
module Matestack
|
17
18
|
module Ui
|
18
19
|
module Bootstrap
|
19
|
-
module
|
20
|
+
module Layouts
|
20
21
|
end
|
21
22
|
end
|
22
23
|
end
|
23
24
|
end
|
24
|
-
require "#{base_path}/
|
25
|
+
require "#{base_path}/layouts/admin_template"
|
25
26
|
|
26
27
|
module Matestack
|
27
28
|
module Ui
|
@@ -105,3 +106,4 @@ require "#{base_path}/form/submit"
|
|
105
106
|
require "#{base_path}/form/switch"
|
106
107
|
|
107
108
|
require "#{base_path}/registry"
|
109
|
+
require "#{base_path}/initialize"
|
metadata
CHANGED
@@ -1,15 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: matestack-ui-bootstrap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonas Jabari
|
8
|
-
- Nils Henning
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2022-03-04 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: matestack-ui-core
|
@@ -17,14 +16,28 @@ dependencies:
|
|
17
16
|
requirements:
|
18
17
|
- - "~>"
|
19
18
|
- !ruby/object:Gem::Version
|
20
|
-
version:
|
19
|
+
version: 3.0.0.rc2
|
21
20
|
type: :runtime
|
22
21
|
prerelease: false
|
23
22
|
version_requirements: !ruby/object:Gem::Requirement
|
24
23
|
requirements:
|
25
24
|
- - "~>"
|
26
25
|
- !ruby/object:Gem::Version
|
27
|
-
version:
|
26
|
+
version: 3.0.0.rc2
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: matestack-ui-vuejs
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 3.0.0.rc2
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 3.0.0.rc2
|
28
41
|
description: Bootstrap v5 components for Matestack UI
|
29
42
|
email:
|
30
43
|
- jonas@matestack.io
|
@@ -35,13 +48,7 @@ files:
|
|
35
48
|
- LICENSE
|
36
49
|
- README.md
|
37
50
|
- Rakefile
|
38
|
-
- config/webpack/development.js
|
39
|
-
- config/webpack/environment.js
|
40
|
-
- config/webpack/production.js
|
41
|
-
- config/webpack/test.js
|
42
|
-
- config/webpacker.yml
|
43
51
|
- lib/matestack/ui/bootstrap.rb
|
44
|
-
- lib/matestack/ui/bootstrap/apps/admin_template.rb
|
45
52
|
- lib/matestack/ui/bootstrap/base_component.rb
|
46
53
|
- lib/matestack/ui/bootstrap/base_vue_js_component.rb
|
47
54
|
- lib/matestack/ui/bootstrap/components/accordion.rb
|
@@ -93,12 +100,14 @@ files:
|
|
93
100
|
- lib/matestack/ui/bootstrap/form/switch.rb
|
94
101
|
- lib/matestack/ui/bootstrap/form/textarea.rb
|
95
102
|
- lib/matestack/ui/bootstrap/index.js
|
103
|
+
- lib/matestack/ui/bootstrap/initialize.rb
|
96
104
|
- lib/matestack/ui/bootstrap/layout/column.rb
|
97
105
|
- lib/matestack/ui/bootstrap/layout/container.rb
|
98
106
|
- lib/matestack/ui/bootstrap/layout/row.rb
|
99
107
|
- lib/matestack/ui/bootstrap/layout/sidebar.js
|
100
108
|
- lib/matestack/ui/bootstrap/layout/sidebar.rb
|
101
109
|
- lib/matestack/ui/bootstrap/layout/sidebar.scss
|
110
|
+
- lib/matestack/ui/bootstrap/layouts/admin_template.rb
|
102
111
|
- lib/matestack/ui/bootstrap/registry.rb
|
103
112
|
- lib/matestack/ui/bootstrap/stylesheets/matestack-ui-bootstrap.scss
|
104
113
|
- lib/matestack/ui/bootstrap/version.rb
|
@@ -122,7 +131,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
122
131
|
- !ruby/object:Gem::Version
|
123
132
|
version: '0'
|
124
133
|
requirements: []
|
125
|
-
rubygems_version: 3.1.
|
134
|
+
rubygems_version: 3.1.4
|
126
135
|
signing_key:
|
127
136
|
specification_version: 4
|
128
137
|
summary: Bootstrap v5 components for Matestack UI
|
@@ -1,29 +0,0 @@
|
|
1
|
-
const { environment } = require('@rails/webpacker')
|
2
|
-
|
3
|
-
environment.config.merge({
|
4
|
-
externals: {
|
5
|
-
"matestack-ui-core": "matestack-ui-core",
|
6
|
-
"chart.js": "chart.js",
|
7
|
-
"bootstrap": "bootstrap",
|
8
|
-
"flatpickr": "flatpickr"
|
9
|
-
}
|
10
|
-
})
|
11
|
-
|
12
|
-
// Remove the digest from the output js filename.
|
13
|
-
// https://github.com/matestack/matestack-ui-core/issues/343#issuecomment-581149092
|
14
|
-
//
|
15
|
-
environment.config.set("output.filename", chunkData => {
|
16
|
-
return "[name].js"
|
17
|
-
})
|
18
|
-
|
19
|
-
// Remove the digest from the output css filename.
|
20
|
-
// https://github.com/matestack/matestack-ui-core/issues/343#issuecomment-581149092
|
21
|
-
//
|
22
|
-
// Inspect with:
|
23
|
-
//
|
24
|
-
// console.log(environment.plugins)
|
25
|
-
//
|
26
|
-
const miniCssExtractPlugin = environment.plugins.get('MiniCssExtract')
|
27
|
-
miniCssExtractPlugin.options.filename = "[name].css"
|
28
|
-
|
29
|
-
module.exports = environment
|
@@ -1,33 +0,0 @@
|
|
1
|
-
process.env.NODE_ENV = process.env.NODE_ENV || 'production'
|
2
|
-
|
3
|
-
const environment = require('./environment')
|
4
|
-
|
5
|
-
// Add `.min` to the production versions of the output files.
|
6
|
-
// https://github.com/matestack/matestack-ui-core/issues/343#issuecomment-580246554
|
7
|
-
// https://github.com/matestack/matestack-ui-core/issues/343#issuecomment-581149092
|
8
|
-
//
|
9
|
-
environment.config.set("output.filename", chunkData => {
|
10
|
-
return "[name].min.js"
|
11
|
-
})
|
12
|
-
const miniCssExtractPlugin = environment.plugins.get('MiniCssExtract')
|
13
|
-
miniCssExtractPlugin.options.filename = "[name].min.css"
|
14
|
-
|
15
|
-
// In order to have babel's es5 (ie11) transpiling be applied to all of the
|
16
|
-
// js code, it needs to be included in the loader paths.
|
17
|
-
// https://github.com/rails/webpacker/blob/master/docs/webpack.md
|
18
|
-
// https://github.com/matestack/matestack-ui-core/issues/238
|
19
|
-
//
|
20
|
-
const babelLoader = environment.loaders.get('babel')
|
21
|
-
delete babelLoader.exclude
|
22
|
-
const path = require('path')
|
23
|
-
const matestackUiBootstrapRootPath = path.resolve(__dirname, '../..')
|
24
|
-
babelLoader.include.push(path.resolve(matestackUiBootstrapRootPath, 'app/concepts/matestack/ui/bootstrap'))
|
25
|
-
babelLoader.include.push(path.resolve(matestackUiBootstrapRootPath, 'node_modules'))
|
26
|
-
|
27
|
-
// We also need to tell babel where to find matestack-ui-material if we are using `npm link`.
|
28
|
-
// Otherwise, it won't follow the symlink to `node_modules/matestack-ui-core`.
|
29
|
-
//
|
30
|
-
// const matestackUiCoreRootPath = path.resolve(require.resolve('matestack-ui-core'), '../../../')
|
31
|
-
// babelLoader.include.push(matestackUiCoreRootPath)
|
32
|
-
|
33
|
-
module.exports = environment.toWebpackConfig()
|
data/config/webpack/test.js
DELETED
data/config/webpacker.yml
DELETED
@@ -1,96 +0,0 @@
|
|
1
|
-
# Note: You must restart bin/webpack-dev-server for changes to take effect
|
2
|
-
|
3
|
-
default: &default
|
4
|
-
source_path: app/javascript
|
5
|
-
source_entry_path: packs
|
6
|
-
public_root_path: vendor/assets/javascripts
|
7
|
-
public_output_path: dist
|
8
|
-
cache_path: tmp/cache/webpacker
|
9
|
-
check_yarn_integrity: false
|
10
|
-
webpack_compile_output: true
|
11
|
-
|
12
|
-
# Additional paths webpack should lookup modules
|
13
|
-
# ['app/assets', 'engine/foo/app/assets']
|
14
|
-
additional_paths: ['node_modules']
|
15
|
-
|
16
|
-
# Reload manifest.json on all requests so we reload latest compiled packs
|
17
|
-
cache_manifest: false
|
18
|
-
|
19
|
-
# Extract and emit a css file
|
20
|
-
extract_css: true
|
21
|
-
|
22
|
-
static_assets_extensions:
|
23
|
-
- .jpg
|
24
|
-
- .jpeg
|
25
|
-
- .png
|
26
|
-
- .gif
|
27
|
-
- .tiff
|
28
|
-
- .ico
|
29
|
-
- .svg
|
30
|
-
- .eot
|
31
|
-
- .otf
|
32
|
-
- .ttf
|
33
|
-
- .woff
|
34
|
-
- .woff2
|
35
|
-
|
36
|
-
extensions:
|
37
|
-
- .mjs
|
38
|
-
- .js
|
39
|
-
- .sass
|
40
|
-
- .scss
|
41
|
-
- .css
|
42
|
-
- .module.sass
|
43
|
-
- .module.scss
|
44
|
-
- .module.css
|
45
|
-
- .png
|
46
|
-
- .svg
|
47
|
-
- .gif
|
48
|
-
- .jpeg
|
49
|
-
- .jpg
|
50
|
-
|
51
|
-
development:
|
52
|
-
<<: *default
|
53
|
-
compile: true
|
54
|
-
|
55
|
-
# Verifies that correct packages and versions are installed by inspecting package.json, yarn.lock, and node_modules
|
56
|
-
check_yarn_integrity: true
|
57
|
-
|
58
|
-
# Reference: https://webpack.js.org/configuration/dev-server/
|
59
|
-
dev_server:
|
60
|
-
https: false
|
61
|
-
host: localhost
|
62
|
-
port: 3035
|
63
|
-
public: localhost:3035
|
64
|
-
hmr: false
|
65
|
-
# Inline should be set to true if using HMR
|
66
|
-
inline: true
|
67
|
-
overlay: true
|
68
|
-
compress: true
|
69
|
-
disable_host_check: true
|
70
|
-
use_local_ip: false
|
71
|
-
quiet: false
|
72
|
-
pretty: false
|
73
|
-
headers:
|
74
|
-
'Access-Control-Allow-Origin': '*'
|
75
|
-
watch_options:
|
76
|
-
ignored: '**/node_modules/**'
|
77
|
-
|
78
|
-
|
79
|
-
test:
|
80
|
-
<<: *default
|
81
|
-
compile: true
|
82
|
-
|
83
|
-
# Compile test packs to a separate directory
|
84
|
-
public_output_path: packs-test
|
85
|
-
|
86
|
-
production:
|
87
|
-
<<: *default
|
88
|
-
|
89
|
-
# Production depends on precompilation of packs prior to booting for performance.
|
90
|
-
compile: false
|
91
|
-
|
92
|
-
# Extract and emit a css file
|
93
|
-
extract_css: true
|
94
|
-
|
95
|
-
# Cache manifest.json for performance
|
96
|
-
cache_manifest: true
|