card-mod-bootstrap 0.13.4 → 0.14.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (148) hide show
  1. checksums.yaml +4 -4
  2. data/assets/script/bootstrap_modal_decko.js +1 -1
  3. data/assets/script/manifest.yml +0 -5
  4. data/assets/style/bootstrap_colorpicker.scss +272 -0
  5. data/{lib/stylesheets → assets/style}/font_awesome.css +0 -0
  6. data/assets/style/manifest.yml +14 -0
  7. data/{lib/stylesheets → assets/style}/material_icons.css +0 -0
  8. data/{lib/stylesheets/style_select2_bootstrap.scss → assets/style/select2_bootstrap.scss} +0 -0
  9. data/{lib/stylesheets → assets/style}/style_bootstrap_cards.scss +5 -3
  10. data/locales/de.yml +3 -0
  11. data/set/abstract/bootswatch_theme.rb +44 -69
  12. data/set/all/bootstrap/helper.rb +1 -1
  13. data/set/type/customized_bootswatch_skin.rb +7 -10
  14. metadata +20 -165
  15. data/assets/script/script_pointer_config.js.coffee +0 -80
  16. data/assets/script/script_pointer_list_editor.js.coffee +0 -67
  17. data/file/cerulean_skin_image/image-icon.png +0 -0
  18. data/file/cerulean_skin_image/image-large.png +0 -0
  19. data/file/cerulean_skin_image/image-medium.png +0 -0
  20. data/file/cerulean_skin_image/image-original.png +0 -0
  21. data/file/cerulean_skin_image/image-small.png +0 -0
  22. data/file/cosmo_skin_image/image-icon.png +0 -0
  23. data/file/cosmo_skin_image/image-large.png +0 -0
  24. data/file/cosmo_skin_image/image-medium.png +0 -0
  25. data/file/cosmo_skin_image/image-original.png +0 -0
  26. data/file/cosmo_skin_image/image-small.png +0 -0
  27. data/file/cyborg_skin_image/image-icon.png +0 -0
  28. data/file/cyborg_skin_image/image-large.png +0 -0
  29. data/file/cyborg_skin_image/image-medium.png +0 -0
  30. data/file/cyborg_skin_image/image-original.png +0 -0
  31. data/file/cyborg_skin_image/image-small.png +0 -0
  32. data/file/darkly_skin_image/image-icon.png +0 -0
  33. data/file/darkly_skin_image/image-large.png +0 -0
  34. data/file/darkly_skin_image/image-medium.png +0 -0
  35. data/file/darkly_skin_image/image-original.png +0 -0
  36. data/file/darkly_skin_image/image-small.png +0 -0
  37. data/file/flatly_skin_image/image-icon.png +0 -0
  38. data/file/flatly_skin_image/image-large.png +0 -0
  39. data/file/flatly_skin_image/image-medium.png +0 -0
  40. data/file/flatly_skin_image/image-original.png +0 -0
  41. data/file/flatly_skin_image/image-small.png +0 -0
  42. data/file/journal_skin_image/image-icon.png +0 -0
  43. data/file/journal_skin_image/image-large.png +0 -0
  44. data/file/journal_skin_image/image-medium.png +0 -0
  45. data/file/journal_skin_image/image-original.png +0 -0
  46. data/file/journal_skin_image/image-small.png +0 -0
  47. data/file/litera_skin_image/image-icon.png +0 -0
  48. data/file/litera_skin_image/image-large.png +0 -0
  49. data/file/litera_skin_image/image-medium.png +0 -0
  50. data/file/litera_skin_image/image-original.png +0 -0
  51. data/file/litera_skin_image/image-small.png +0 -0
  52. data/file/lumen_skin_image/image-icon.png +0 -0
  53. data/file/lumen_skin_image/image-large.png +0 -0
  54. data/file/lumen_skin_image/image-medium.png +0 -0
  55. data/file/lumen_skin_image/image-original.png +0 -0
  56. data/file/lumen_skin_image/image-small.png +0 -0
  57. data/file/lux_skin_image/image-icon.png +0 -0
  58. data/file/lux_skin_image/image-large.png +0 -0
  59. data/file/lux_skin_image/image-medium.png +0 -0
  60. data/file/lux_skin_image/image-original.png +0 -0
  61. data/file/lux_skin_image/image-small.png +0 -0
  62. data/file/materia_skin_image/image-icon.png +0 -0
  63. data/file/materia_skin_image/image-large.png +0 -0
  64. data/file/materia_skin_image/image-medium.png +0 -0
  65. data/file/materia_skin_image/image-original.png +0 -0
  66. data/file/materia_skin_image/image-small.png +0 -0
  67. data/file/minty_skin_image/image-icon.png +0 -0
  68. data/file/minty_skin_image/image-large.png +0 -0
  69. data/file/minty_skin_image/image-medium.png +0 -0
  70. data/file/minty_skin_image/image-original.png +0 -0
  71. data/file/minty_skin_image/image-small.png +0 -0
  72. data/file/mod_bootstrap_script_bootstrap_machine_output/file.js +0 -25
  73. data/file/mod_bootstrap_script_pointer_machine_output/file.js +0 -223
  74. data/file/paper_skin_image/image-icon.png +0 -0
  75. data/file/paper_skin_image/image-large.png +0 -0
  76. data/file/paper_skin_image/image-medium.png +0 -0
  77. data/file/paper_skin_image/image-original.png +0 -0
  78. data/file/paper_skin_image/image-small.png +0 -0
  79. data/file/pulse_skin_image/image-icon.png +0 -0
  80. data/file/pulse_skin_image/image-large.png +0 -0
  81. data/file/pulse_skin_image/image-medium.png +0 -0
  82. data/file/pulse_skin_image/image-original.png +0 -0
  83. data/file/pulse_skin_image/image-small.png +0 -0
  84. data/file/readable_skin_image/image-icon.png +0 -0
  85. data/file/readable_skin_image/image-large.png +0 -0
  86. data/file/readable_skin_image/image-medium.png +0 -0
  87. data/file/readable_skin_image/image-original.png +0 -0
  88. data/file/readable_skin_image/image-small.png +0 -0
  89. data/file/sandstone_skin_image/image-icon.png +0 -0
  90. data/file/sandstone_skin_image/image-large.png +0 -0
  91. data/file/sandstone_skin_image/image-medium.png +0 -0
  92. data/file/sandstone_skin_image/image-original.png +0 -0
  93. data/file/sandstone_skin_image/image-small.png +0 -0
  94. data/file/simplex_skin_image/image-icon.png +0 -0
  95. data/file/simplex_skin_image/image-large.png +0 -0
  96. data/file/simplex_skin_image/image-medium.png +0 -0
  97. data/file/simplex_skin_image/image-original.png +0 -0
  98. data/file/simplex_skin_image/image-small.png +0 -0
  99. data/file/sketchy_skin_image/image-icon.png +0 -0
  100. data/file/sketchy_skin_image/image-large.png +0 -0
  101. data/file/sketchy_skin_image/image-medium.png +0 -0
  102. data/file/sketchy_skin_image/image-original.png +0 -0
  103. data/file/sketchy_skin_image/image-small.png +0 -0
  104. data/file/slate_skin_image/image-icon.png +0 -0
  105. data/file/slate_skin_image/image-large.png +0 -0
  106. data/file/slate_skin_image/image-medium.png +0 -0
  107. data/file/slate_skin_image/image-original.png +0 -0
  108. data/file/slate_skin_image/image-small.png +0 -0
  109. data/file/solar_skin_image/image-icon.png +0 -0
  110. data/file/solar_skin_image/image-large.png +0 -0
  111. data/file/solar_skin_image/image-medium.png +0 -0
  112. data/file/solar_skin_image/image-original.png +0 -0
  113. data/file/solar_skin_image/image-small.png +0 -0
  114. data/file/spacelab_skin_image/image-icon.png +0 -0
  115. data/file/spacelab_skin_image/image-large.png +0 -0
  116. data/file/spacelab_skin_image/image-medium.png +0 -0
  117. data/file/spacelab_skin_image/image-original.png +0 -0
  118. data/file/spacelab_skin_image/image-small.png +0 -0
  119. data/file/superhero_skin_image/image-icon.png +0 -0
  120. data/file/superhero_skin_image/image-large.png +0 -0
  121. data/file/superhero_skin_image/image-medium.png +0 -0
  122. data/file/superhero_skin_image/image-original.png +0 -0
  123. data/file/superhero_skin_image/image-small.png +0 -0
  124. data/file/united_skin_image/image-icon.png +0 -0
  125. data/file/united_skin_image/image-large.png +0 -0
  126. data/file/united_skin_image/image-medium.png +0 -0
  127. data/file/united_skin_image/image-original.png +0 -0
  128. data/file/united_skin_image/image-small.png +0 -0
  129. data/file/yeti_skin_image/image-icon.png +0 -0
  130. data/file/yeti_skin_image/image-large.png +0 -0
  131. data/file/yeti_skin_image/image-medium.png +0 -0
  132. data/file/yeti_skin_image/image-original.png +0 -0
  133. data/file/yeti_skin_image/image-small.png +0 -0
  134. data/lib/card/lazy_tab.rb +0 -37
  135. data/lib/card/tab.rb +0 -83
  136. data/lib/javascript/smartmenu.js +0 -94
  137. data/lib/stylesheets/smartmenu.css +0 -433
  138. data/set/all/bootstrap/tabs/tab_panel.haml +0 -7
  139. data/set/all/bootstrap/tabs.rb +0 -40
  140. data/set/self/font_awesome.rb +0 -2
  141. data/set/self/material_icons.rb +0 -2
  142. data/set/self/script_load_select2.rb +0 -2
  143. data/set/self/smartmenu_css.rb +0 -5
  144. data/set/self/smartmenu_js.rb +0 -5
  145. data/set/self/style_bootstrap_cards.rb +0 -1
  146. data/set/self/style_bootstrap_colorpicker.rb +0 -6
  147. data/set/self/style_select2.rb +0 -10
  148. data/set/self/style_select2_bootstrap.rb +0 -1
@@ -1,223 +0,0 @@
1
- // script_pointer_config.js.coffee
2
- (function() {
3
- var permissionsContent, pointerContent;
4
-
5
- $.extend(decko.editorContentFunctionMap, {
6
- 'select.pointer-select': function() {
7
- return pointerContent(this.val());
8
- },
9
- 'select.pointer-multiselect': function() {
10
- return pointerContent(this.val());
11
- },
12
- '.pointer-radio-list': function() {
13
- return pointerContent(this.find('input:checked').val());
14
- },
15
- '.pointer-list-ul': function() {
16
- return pointerContent(this.find('input').map(function() {
17
- return $(this).val();
18
- }));
19
- },
20
- '.pointer-link-list-ul': function() {
21
- return decko.linkListContent(this.find('.input-group'));
22
- },
23
- '._nest-list-ul': function() {
24
- return decko.nestListContent(this.find('.input-group'));
25
- },
26
- '.pointer-checkbox-list': function() {
27
- return pointerContent(this.find('input:checked').map(function() {
28
- return $(this).val();
29
- }));
30
- },
31
- '.pointer-select-list': function() {
32
- return pointerContent(this.find('.pointer-select select').map(function() {
33
- return $(this).val();
34
- }));
35
- },
36
- '._pointer-filtered-list': function() {
37
- return pointerContent(this.find('._filtered-list-item').map(function() {
38
- return $(this).data('cardName');
39
- }));
40
- },
41
- '._pointer-list': function() {
42
- return pointerContent(this.find('._pointer-item').map(function() {
43
- return $(this).val();
44
- }));
45
- },
46
- '.perm-editor': function() {
47
- return permissionsContent(this);
48
- }
49
- });
50
-
51
- decko.editorInitFunctionMap['.pointer-list-editor'] = function() {
52
- this.sortable({
53
- handle: '.handle',
54
- cancel: ''
55
- });
56
- return decko.initPointerList(this.find('input'));
57
- };
58
-
59
- decko.editorInitFunctionMap['._pointer-filtered-list'] = function() {
60
- return this.sortable({
61
- handle: '._handle',
62
- cancel: ''
63
- });
64
- };
65
-
66
- $.extend(decko, {
67
- initPointerList: function(input) {
68
- return decko.initAutoCardPlete(input);
69
- },
70
- initAutoCardPlete: function(input) {
71
- var optionsCard, path;
72
- optionsCard = input.data('options-card');
73
- if (!optionsCard) {
74
- return;
75
- }
76
- path = optionsCard + '.json?view=name_match';
77
- return input.autocomplete({
78
- source: decko.slotPath(path)
79
- });
80
- },
81
- pointerContent: function(vals) {
82
- var list;
83
- list = $.map($.makeArray(vals), function(v) {
84
- if (v) {
85
- return '[[' + v + ']]';
86
- }
87
- });
88
- return $.makeArray(list).join("\n");
89
- },
90
- linkListContent: function(input_groups) {
91
- var list, vals;
92
- vals = input_groups.map(function() {
93
- var title, v;
94
- v = $(this).find('input._reference').val();
95
- title = $(this).find('input._title').val();
96
- if (title.length > 0) {
97
- v += "|" + title;
98
- }
99
- return v;
100
- });
101
- list = $.map($.makeArray(vals), function(v) {
102
- if (v) {
103
- return '[[' + v + ']]';
104
- }
105
- });
106
- return $.makeArray(list).join("\n");
107
- },
108
- nestListContent: function(input_groups) {
109
- var list, vals;
110
- vals = input_groups.map(function() {
111
- var options, v;
112
- v = $(this).find('input._reference').val();
113
- options = $(this).find('input._nest-options').val();
114
- if (options.length > 0) {
115
- v += "|" + options;
116
- }
117
- return v;
118
- });
119
- list = $.map($.makeArray(vals), function(v) {
120
- if (v) {
121
- return '{{' + v + '}}';
122
- }
123
- });
124
- return $.makeArray(list).join("\n");
125
- }
126
- });
127
-
128
- pointerContent = function(vals) {
129
- return decko.pointerContent(vals);
130
- };
131
-
132
- permissionsContent = function(ed) {
133
- var groups, indivs;
134
- if (ed.find('#inherit').is(':checked')) {
135
- return '_left';
136
- }
137
- groups = ed.find('.perm-group input:checked').map(function() {
138
- return $(this).val();
139
- });
140
- indivs = ed.find('.perm-indiv input').map(function() {
141
- return $(this).val();
142
- });
143
- return pointerContent($.makeArray(groups).concat($.makeArray(indivs)));
144
- };
145
-
146
- }).call(this);
147
-
148
- // script_pointer_list_editor.js.coffee
149
- (function() {
150
- $(window).ready(function() {
151
- $('body').on('click', '._pointer-item-add', function(event) {
152
- decko.addPointerItem(this);
153
- return event.preventDefault();
154
- });
155
- $('body').on('keydown', '.pointer-item-text', function(event) {
156
- if (event.key === 'Enter') {
157
- decko.addPointerItem(this);
158
- return event.preventDefault();
159
- }
160
- });
161
- $('body').on('keyup', '.pointer-item-text', function(_event) {
162
- return decko.updateAddItemButton(this);
163
- });
164
- return $('body').on('click', '.pointer-item-delete', function() {
165
- var item, list;
166
- item = $(this).closest('li');
167
- list = item.closest('ul');
168
- if (list.find('.pointer-li').length > 1) {
169
- item.remove();
170
- } else {
171
- item.find('input').val('');
172
- }
173
- return decko.updateAddItemButton(list);
174
- });
175
- });
176
-
177
- decko.slotReady(function(slot) {
178
- return slot.find('.pointer-list-editor').each(function() {
179
- return decko.updateAddItemButton(this);
180
- });
181
- });
182
-
183
- $.extend(decko, {
184
- addPointerItem: function(el) {
185
- var newInput, slot;
186
- slot = $(el).slot();
187
- slot.trigger("slotDestroy");
188
- newInput = decko.nextPointerInput(decko.lastPointerItem(el));
189
- newInput.val('');
190
- slot.trigger("slotReady");
191
- decko.initializeEditors(slot);
192
- newInput.first().focus();
193
- decko.updateAddItemButton(el);
194
- return decko.initPointerList(newInput);
195
- },
196
- nextPointerInput: function(lastItem) {
197
- var all_empty, i, input, lastInputs, len, newItem;
198
- lastInputs = lastItem.find('input');
199
- all_empty = true;
200
- for (i = 0, len = lastInputs.length; i < len; i++) {
201
- input = lastInputs[i];
202
- all_empty = all_empty && $(input).val() === '';
203
- }
204
- if (all_empty) {
205
- return lastInputs;
206
- }
207
- newItem = lastItem.clone();
208
- lastItem.after(newItem);
209
- newItem.attr("data-index", parseInt(lastItem.attr("data-index") + 1));
210
- return newItem.find('input');
211
- },
212
- lastPointerItem: function(el) {
213
- return $(el).closest('.content-editor').find('.pointer-li:last');
214
- },
215
- updateAddItemButton: function(el) {
216
- var button, disabled;
217
- button = $(el).closest('.content-editor').find('._pointer-item-add');
218
- disabled = decko.lastPointerItem(el).find('input').val() === '';
219
- return button.prop('disabled', disabled);
220
- }
221
- });
222
-
223
- }).call(this);
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
data/lib/card/lazy_tab.rb DELETED
@@ -1,37 +0,0 @@
1
- class Card
2
- class LazyTab < Tab
3
- def url
4
- @url ||= (config_hash? && @config[:path]) || format.path(view: view)
5
- end
6
-
7
- def view
8
- @view ||= (config_hash? && @config[:view]) || @config
9
- end
10
-
11
- def tab_button
12
- if url
13
- super
14
- else
15
- wrap_with(:li, label, role: "presentation")
16
- end
17
- end
18
-
19
- def button_attrib
20
- @button_attrib ||= super.merge("data-url" => url.html_safe)
21
- end
22
-
23
- def tab_button_link
24
- add_class button_attrib, "load" unless active?
25
- super
26
- end
27
-
28
- def content
29
- @content ||= ""
30
- end
31
-
32
- def tab_pane args=nil, &block
33
- @content = yield if active? && block_given?
34
- super
35
- end
36
- end
37
- end
data/lib/card/tab.rb DELETED
@@ -1,83 +0,0 @@
1
- class Card
2
- class Tab
3
- attr_reader :format, :name, :label, :content, :button_attrib
4
-
5
- class << self
6
- def tab_objects format, tab_hash, active_name, klass=nil
7
- klass ||= Card::Tab
8
- active_name = active active_name, tab_hash.keys
9
- tab_hash.map do |name, config|
10
- klass.new format, name, active_name, config
11
- end
12
- end
13
-
14
- private
15
-
16
- def active requested, keys
17
- r = requested.to_name
18
- r && keys.find { |k| k.to_name == r } || keys.first
19
- end
20
- end
21
-
22
- delegate :add_class, :wrap_with, :unique_id, :link_to, to: :format
23
-
24
- def initialize format, name, active_name, config
25
- @format = format
26
- @name = name
27
- @active_name = active_name
28
- @config = config
29
- end
30
-
31
- def tab_button
32
- add_class button_attrib, "active" if active?
33
- wrap_with :li, tab_button_link,
34
- role: :presentation,
35
- class: "nav-item tab-li-#{name}"
36
- end
37
-
38
- def tab_pane args=nil
39
- pane_attr = { role: :tabpanel, id: tab_id }
40
- pane_attr.merge! args if args.present?
41
- add_class pane_attr, "tab-pane tab-pane-#{name}"
42
- add_class pane_attr, "active" if active?
43
- wrap_with :div, content, pane_attr
44
- end
45
-
46
- private
47
-
48
- def config_hash?
49
- @config.is_a? Hash
50
- end
51
-
52
- def label
53
- @label ||= (config_hash? && @config[:title]) || name
54
- end
55
-
56
- def content
57
- @content ||= config_hash? ? @config[:content] : @config
58
- end
59
-
60
- def button_attrib
61
- @button_attrib ||= (config_hash? && @config[:button_attr]) || {}
62
- end
63
-
64
- def tab_button_link
65
- add_class button_attrib, "nav-link"
66
-
67
- link_to label, button_attrib.merge(
68
- path: "##{tab_id}",
69
- role: "tab",
70
- "data-toggle" => "tab",
71
- "data-tab-name" => name
72
- )
73
- end
74
-
75
- def tab_id
76
- @tab_id ||= "#{unique_id}-#{name.to_name.safe_key}"
77
- end
78
-
79
- def active?
80
- name == @active_name
81
- end
82
- end
83
- end