fomantic-ui 2.10.0-beta.6 → 2.10.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (227) hide show
  1. package/.eslintrc.js +0 -10
  2. package/README.md +4 -5
  3. package/changelog-setup.js +64 -70
  4. package/dist/components/accordion.css +1 -1
  5. package/dist/components/accordion.js +94 -131
  6. package/dist/components/accordion.min.css +1 -1
  7. package/dist/components/accordion.min.js +2 -2
  8. package/dist/components/ad.css +1 -1
  9. package/dist/components/ad.min.css +1 -1
  10. package/dist/components/api.js +152 -205
  11. package/dist/components/api.min.js +2 -2
  12. package/dist/components/breadcrumb.css +1 -1
  13. package/dist/components/breadcrumb.min.css +1 -1
  14. package/dist/components/button.css +1 -1
  15. package/dist/components/button.min.css +1 -1
  16. package/dist/components/calendar.css +1 -1
  17. package/dist/components/calendar.js +305 -341
  18. package/dist/components/calendar.min.css +1 -1
  19. package/dist/components/calendar.min.js +2 -2
  20. package/dist/components/card.css +1 -1
  21. package/dist/components/card.min.css +1 -1
  22. package/dist/components/checkbox.css +1 -1
  23. package/dist/components/checkbox.js +76 -116
  24. package/dist/components/checkbox.min.css +1 -1
  25. package/dist/components/checkbox.min.js +2 -2
  26. package/dist/components/comment.css +1 -1
  27. package/dist/components/comment.min.css +1 -1
  28. package/dist/components/container.css +1 -1
  29. package/dist/components/container.min.css +1 -1
  30. package/dist/components/dimmer.css +1 -1
  31. package/dist/components/dimmer.js +58 -91
  32. package/dist/components/dimmer.min.css +1 -1
  33. package/dist/components/dimmer.min.js +2 -2
  34. package/dist/components/divider.css +1 -1
  35. package/dist/components/divider.min.css +1 -1
  36. package/dist/components/dropdown.css +1 -1
  37. package/dist/components/dropdown.js +674 -977
  38. package/dist/components/dropdown.min.css +1 -1
  39. package/dist/components/dropdown.min.js +2 -2
  40. package/dist/components/embed.css +1 -1
  41. package/dist/components/embed.js +80 -127
  42. package/dist/components/embed.min.css +1 -1
  43. package/dist/components/embed.min.js +2 -2
  44. package/dist/components/emoji.css +1 -1
  45. package/dist/components/emoji.min.css +1 -1
  46. package/dist/components/feed.css +1 -1
  47. package/dist/components/feed.min.css +1 -1
  48. package/dist/components/flag.css +1 -1
  49. package/dist/components/flag.min.css +1 -1
  50. package/dist/components/flyout.css +1 -1
  51. package/dist/components/flyout.js +192 -274
  52. package/dist/components/flyout.min.css +1 -1
  53. package/dist/components/flyout.min.js +2 -2
  54. package/dist/components/form.css +1 -1
  55. package/dist/components/form.js +325 -429
  56. package/dist/components/form.min.css +1 -1
  57. package/dist/components/form.min.js +2 -2
  58. package/dist/components/grid.css +1 -1
  59. package/dist/components/grid.min.css +1 -1
  60. package/dist/components/header.css +1 -1
  61. package/dist/components/header.min.css +1 -1
  62. package/dist/components/icon.css +1 -1
  63. package/dist/components/icon.min.css +1 -1
  64. package/dist/components/image.css +1 -1
  65. package/dist/components/image.min.css +1 -1
  66. package/dist/components/input.css +1 -1
  67. package/dist/components/input.min.css +1 -1
  68. package/dist/components/item.css +1 -1
  69. package/dist/components/item.min.css +1 -1
  70. package/dist/components/label.css +1 -1
  71. package/dist/components/label.min.css +1 -1
  72. package/dist/components/list.css +1 -1
  73. package/dist/components/list.min.css +1 -1
  74. package/dist/components/loader.css +1 -1
  75. package/dist/components/loader.min.css +1 -1
  76. package/dist/components/menu.css +1 -1
  77. package/dist/components/menu.min.css +1 -1
  78. package/dist/components/message.css +1 -1
  79. package/dist/components/message.min.css +1 -1
  80. package/dist/components/modal.css +1 -1
  81. package/dist/components/modal.js +221 -313
  82. package/dist/components/modal.min.css +1 -1
  83. package/dist/components/modal.min.js +2 -2
  84. package/dist/components/nag.css +1 -1
  85. package/dist/components/nag.js +67 -97
  86. package/dist/components/nag.min.css +1 -1
  87. package/dist/components/nag.min.js +2 -2
  88. package/dist/components/placeholder.css +1 -1
  89. package/dist/components/placeholder.min.css +1 -1
  90. package/dist/components/popup.css +1 -1
  91. package/dist/components/popup.js +185 -254
  92. package/dist/components/popup.min.css +1 -1
  93. package/dist/components/popup.min.js +2 -2
  94. package/dist/components/progress.css +1 -1
  95. package/dist/components/progress.js +103 -138
  96. package/dist/components/progress.min.css +1 -1
  97. package/dist/components/progress.min.js +2 -2
  98. package/dist/components/rail.css +1 -1
  99. package/dist/components/rail.min.css +1 -1
  100. package/dist/components/rating.css +1 -1
  101. package/dist/components/rating.js +89 -139
  102. package/dist/components/rating.min.css +1 -1
  103. package/dist/components/rating.min.js +2 -2
  104. package/dist/components/reset.css +1 -1
  105. package/dist/components/reset.min.css +1 -1
  106. package/dist/components/reveal.css +1 -1
  107. package/dist/components/reveal.min.css +1 -1
  108. package/dist/components/search.css +1 -1
  109. package/dist/components/search.js +253 -352
  110. package/dist/components/search.min.css +1 -1
  111. package/dist/components/search.min.js +2 -2
  112. package/dist/components/segment.css +1 -1
  113. package/dist/components/segment.min.css +1 -1
  114. package/dist/components/shape.css +1 -1
  115. package/dist/components/shape.js +157 -223
  116. package/dist/components/shape.min.css +1 -1
  117. package/dist/components/shape.min.js +2 -2
  118. package/dist/components/sidebar.css +1 -1
  119. package/dist/components/sidebar.js +122 -163
  120. package/dist/components/sidebar.min.css +1 -1
  121. package/dist/components/sidebar.min.js +2 -2
  122. package/dist/components/site.css +1 -1
  123. package/dist/components/site.js +38 -57
  124. package/dist/components/site.min.css +1 -1
  125. package/dist/components/site.min.js +2 -2
  126. package/dist/components/slider.css +1 -1
  127. package/dist/components/slider.js +242 -325
  128. package/dist/components/slider.min.css +1 -1
  129. package/dist/components/slider.min.js +2 -2
  130. package/dist/components/state.js +68 -98
  131. package/dist/components/state.min.js +2 -2
  132. package/dist/components/statistic.css +1 -1
  133. package/dist/components/statistic.min.css +1 -1
  134. package/dist/components/step.css +1 -1
  135. package/dist/components/step.min.css +1 -1
  136. package/dist/components/sticky.css +1 -1
  137. package/dist/components/sticky.js +116 -159
  138. package/dist/components/sticky.min.css +1 -1
  139. package/dist/components/sticky.min.js +2 -2
  140. package/dist/components/tab.css +1 -1
  141. package/dist/components/tab.js +168 -233
  142. package/dist/components/tab.min.css +1 -1
  143. package/dist/components/tab.min.js +2 -2
  144. package/dist/components/table.css +1 -1
  145. package/dist/components/table.min.css +1 -1
  146. package/dist/components/text.css +1 -1
  147. package/dist/components/text.min.css +1 -1
  148. package/dist/components/toast.css +1 -1
  149. package/dist/components/toast.js +99 -132
  150. package/dist/components/toast.min.css +1 -1
  151. package/dist/components/toast.min.js +2 -2
  152. package/dist/components/transition.css +1 -1
  153. package/dist/components/transition.js +86 -141
  154. package/dist/components/transition.min.css +1 -1
  155. package/dist/components/transition.min.js +2 -2
  156. package/dist/components/visibility.js +134 -210
  157. package/dist/components/visibility.min.js +2 -2
  158. package/dist/semantic.css +53 -53
  159. package/dist/semantic.js +4100 -5721
  160. package/dist/semantic.min.css +1 -1
  161. package/dist/semantic.min.js +2 -2
  162. package/examples/assets/show-examples.js +2 -4
  163. package/gulpfile.js +5 -7
  164. package/package.json +1 -1
  165. package/scripts/nightly-version.js +7 -10
  166. package/src/definitions/behaviors/api.js +151 -204
  167. package/src/definitions/behaviors/form.js +324 -428
  168. package/src/definitions/behaviors/state.js +67 -97
  169. package/src/definitions/behaviors/visibility.js +133 -209
  170. package/src/definitions/globals/site.js +37 -56
  171. package/src/definitions/modules/accordion.js +93 -130
  172. package/src/definitions/modules/calendar.js +304 -340
  173. package/src/definitions/modules/checkbox.js +75 -115
  174. package/src/definitions/modules/dimmer.js +57 -90
  175. package/src/definitions/modules/dropdown.js +673 -976
  176. package/src/definitions/modules/embed.js +79 -126
  177. package/src/definitions/modules/flyout.js +191 -273
  178. package/src/definitions/modules/modal.js +220 -312
  179. package/src/definitions/modules/nag.js +66 -96
  180. package/src/definitions/modules/popup.js +184 -253
  181. package/src/definitions/modules/progress.js +102 -137
  182. package/src/definitions/modules/rating.js +88 -138
  183. package/src/definitions/modules/search.js +252 -351
  184. package/src/definitions/modules/shape.js +156 -222
  185. package/src/definitions/modules/sidebar.js +121 -162
  186. package/src/definitions/modules/slider.js +241 -324
  187. package/src/definitions/modules/sticky.js +115 -158
  188. package/src/definitions/modules/tab.js +167 -232
  189. package/src/definitions/modules/toast.js +98 -131
  190. package/src/definitions/modules/transition.js +85 -140
  191. package/tasks/admin/components/create.js +88 -108
  192. package/tasks/admin/components/init.js +26 -32
  193. package/tasks/admin/components/update.js +46 -53
  194. package/tasks/admin/distributions/create.js +71 -101
  195. package/tasks/admin/distributions/init.js +27 -33
  196. package/tasks/admin/distributions/update.js +45 -52
  197. package/tasks/admin/register.js +11 -15
  198. package/tasks/build/assets.js +14 -18
  199. package/tasks/build/css.js +54 -63
  200. package/tasks/build/javascript.js +45 -53
  201. package/tasks/build.js +4 -6
  202. package/tasks/check-install.js +5 -7
  203. package/tasks/clean.js +2 -4
  204. package/tasks/collections/admin.js +13 -15
  205. package/tasks/collections/build.js +6 -8
  206. package/tasks/collections/docs.js +2 -4
  207. package/tasks/collections/install.js +2 -4
  208. package/tasks/collections/rtl.js +2 -4
  209. package/tasks/collections/various.js +2 -4
  210. package/tasks/config/admin/github.js +7 -9
  211. package/tasks/config/admin/templates/css-package.js +1 -3
  212. package/tasks/config/admin/templates/less-package.js +1 -3
  213. package/tasks/config/npm/gulpfile.js +4 -6
  214. package/tasks/config/project/config.js +22 -30
  215. package/tasks/config/project/install.js +56 -70
  216. package/tasks/config/project/release.js +6 -8
  217. package/tasks/config/tasks.js +8 -12
  218. package/tasks/config/user.js +13 -17
  219. package/tasks/docs/build.js +26 -31
  220. package/tasks/docs/metadata.js +24 -30
  221. package/tasks/docs/serve.js +20 -26
  222. package/tasks/install.js +71 -98
  223. package/tasks/rtl/build.js +2 -4
  224. package/tasks/rtl/watch.js +2 -4
  225. package/tasks/watch.js +9 -11
  226. package/test/meteor/fonts.js +1 -2
  227. package/test/modules/module.spec.js +16 -18
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Embed
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Embed
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -20,45 +20,41 @@
20
20
  : globalThis;
21
21
 
22
22
  $.fn.embed = function (parameters) {
23
- var
24
- $allModules = $(this),
23
+ let $allModules = $(this);
25
24
 
26
- time = Date.now(),
27
- performance = [],
25
+ let time = Date.now();
26
+ let performance = [];
28
27
 
29
- query = arguments[0],
30
- methodInvoked = typeof query === 'string',
31
- queryArguments = [].slice.call(arguments, 1),
28
+ let query = arguments[0];
29
+ let methodInvoked = typeof query === 'string';
30
+ let queryArguments = [].slice.call(arguments, 1);
32
31
 
33
- returnedValue
34
- ;
32
+ let returnedValue;
35
33
 
36
34
  $allModules.each(function () {
37
- var
38
- settings = $.isPlainObject(parameters)
39
- ? $.extend(true, {}, $.fn.embed.settings, parameters)
40
- : $.extend({}, $.fn.embed.settings),
41
-
42
- selector = settings.selector,
43
- className = settings.className,
44
- sources = settings.sources,
45
- error = settings.error,
46
- metadata = settings.metadata,
47
- namespace = settings.namespace,
48
- templates = settings.templates,
49
-
50
- eventNamespace = '.' + namespace,
51
- moduleNamespace = 'module-' + namespace,
52
-
53
- $module = $(this),
54
- $placeholder = $module.find(selector.placeholder),
55
- $icon = $module.find(selector.icon),
56
- $embed = $module.find(selector.embed),
57
-
58
- element = this,
59
- instance = $module.data(moduleNamespace),
60
- module
61
- ;
35
+ let settings = $.isPlainObject(parameters)
36
+ ? $.extend(true, {}, $.fn.embed.settings, parameters)
37
+ : $.extend({}, $.fn.embed.settings);
38
+
39
+ let selector = settings.selector;
40
+ let className = settings.className;
41
+ let sources = settings.sources;
42
+ let error = settings.error;
43
+ let metadata = settings.metadata;
44
+ let namespace = settings.namespace;
45
+ let templates = settings.templates;
46
+
47
+ let eventNamespace = '.' + namespace;
48
+ let moduleNamespace = 'module-' + namespace;
49
+
50
+ let $module = $(this);
51
+ let $placeholder = $module.find(selector.placeholder);
52
+ let $icon = $module.find(selector.icon);
53
+ let $embed = $module.find(selector.embed);
54
+
55
+ let element = this;
56
+ let instance = $module.data(moduleNamespace);
57
+ let module;
62
58
 
63
59
  module = {
64
60
 
@@ -74,8 +70,7 @@
74
70
  module.verbose('Storing instance of module', module);
75
71
  instance = module;
76
72
  $module
77
- .data(moduleNamespace, module)
78
- ;
73
+ .data(moduleNamespace, module);
79
74
  },
80
75
 
81
76
  destroy: function () {
@@ -83,8 +78,7 @@
83
78
  module.reset();
84
79
  $module
85
80
  .removeData(moduleNamespace)
86
- .off(eventNamespace)
87
- ;
81
+ .off(eventNamespace);
88
82
  },
89
83
 
90
84
  refresh: function () {
@@ -100,16 +94,13 @@
100
94
  module.debug('Adding placeholder events');
101
95
  $module
102
96
  .on('click' + eventNamespace, selector.placeholder, module.createAndShow)
103
- .on('click' + eventNamespace, selector.icon, module.createAndShow)
104
- ;
97
+ .on('click' + eventNamespace, selector.icon, module.createAndShow);
105
98
  }
106
99
  },
107
100
  },
108
101
 
109
102
  create: function () {
110
- var
111
- placeholder = module.get.placeholder()
112
- ;
103
+ let placeholder = module.get.placeholder();
113
104
  if (placeholder) {
114
105
  module.createPlaceholder();
115
106
  } else {
@@ -118,10 +109,8 @@
118
109
  },
119
110
 
120
111
  createPlaceholder: function (placeholder) {
121
- var
122
- icon = module.get.icon(),
123
- alt = module.get.alt()
124
- ;
112
+ let icon = module.get.icon();
113
+ let alt = module.get.alt();
125
114
  placeholder = placeholder || module.get.placeholder();
126
115
  $module.html(templates.placeholder(placeholder, icon, alt));
127
116
  module.debug('Creating placeholder for embed', placeholder, icon, alt);
@@ -133,16 +122,14 @@
133
122
  $embed = $('<div/>')
134
123
  .addClass(className.embed)
135
124
  .html(module.generate.embed(url))
136
- .appendTo($module)
137
- ;
125
+ .appendTo($module);
138
126
  settings.onCreate.call(element, url);
139
127
  module.debug('Creating embed object', $embed);
140
128
  },
141
129
 
142
130
  changeEmbed: function (url) {
143
131
  $embed
144
- .html(module.generate.embed(url))
145
- ;
132
+ .html(module.generate.embed(url));
146
133
  },
147
134
 
148
135
  createAndShow: function () {
@@ -155,8 +142,7 @@
155
142
  module.debug('Changing video to ', source, id, url);
156
143
  $module
157
144
  .data(metadata.source, source)
158
- .data(metadata.id, id)
159
- ;
145
+ .data(metadata.id, id);
160
146
  if (url) {
161
147
  $module.data(metadata.url, url);
162
148
  } else {
@@ -218,7 +204,7 @@
218
204
  : module.determine.source());
219
205
  },
220
206
  type: function () {
221
- var source = module.get.source();
207
+ let source = module.get.source();
222
208
 
223
209
  return sources[source] !== undefined
224
210
  ? sources[source].type
@@ -238,9 +224,7 @@
238
224
  }
239
225
  },
240
226
  source: function (url) {
241
- var
242
- matchedSource = false
243
- ;
227
+ let matchedSource = false;
244
228
  url = url || module.get.url();
245
229
  if (url) {
246
230
  $.each(sources, function (name, source) {
@@ -255,20 +239,16 @@
255
239
  return matchedSource;
256
240
  },
257
241
  icon: function () {
258
- var
259
- source = module.get.source()
260
- ;
242
+ let source = module.get.source();
261
243
 
262
244
  return sources[source] !== undefined
263
245
  ? sources[source].icon
264
246
  : false;
265
247
  },
266
248
  url: function () {
267
- var
268
- id = settings.id || $module.data(metadata.id),
269
- source = settings.source || $module.data(metadata.source),
270
- url
271
- ;
249
+ let id = settings.id || $module.data(metadata.id);
250
+ let source = settings.source || $module.data(metadata.source);
251
+ let url;
272
252
  url = sources[source] !== undefined
273
253
  ? sources[source].url.replace('{id}', id)
274
254
  : false;
@@ -294,8 +274,7 @@
294
274
  .removeData(metadata.placeholder)
295
275
  .removeData(metadata.alt)
296
276
  .removeData(metadata.source)
297
- .removeData(metadata.url)
298
- ;
277
+ .removeData(metadata.url);
299
278
  },
300
279
  active: function () {
301
280
  $module.removeClass(className.active);
@@ -307,10 +286,8 @@
307
286
 
308
287
  encode: {
309
288
  parameters: function (parameters) {
310
- var
311
- urlString = [],
312
- index
313
- ;
289
+ let urlString = [];
290
+ let index;
314
291
  for (index in parameters) {
315
292
  urlString.push(encodeURIComponent(index) + '=' + encodeURIComponent(parameters[index]));
316
293
  }
@@ -322,11 +299,9 @@
322
299
  generate: {
323
300
  embed: function (url) {
324
301
  module.debug('Generating embed html');
325
- var
326
- source = module.get.source(),
327
- html,
328
- parameters
329
- ;
302
+ let source = module.get.source();
303
+ let html;
304
+ let parameters;
330
305
  url = module.get.url(url);
331
306
  if (url) {
332
307
  parameters = module.generate.parameters(source);
@@ -338,11 +313,9 @@
338
313
  return html;
339
314
  },
340
315
  parameters: function (source, extraParameters) {
341
- var
342
- parameters = sources[source] && sources[source].parameters !== undefined
343
- ? sources[source].parameters(settings)
344
- : {}
345
- ;
316
+ let parameters = sources[source] && sources[source].parameters !== undefined
317
+ ? sources[source].parameters(settings)
318
+ : {};
346
319
  extraParameters = extraParameters || settings.parameters;
347
320
  if (extraParameters) {
348
321
  parameters = $.extend({}, parameters, extraParameters);
@@ -427,11 +400,9 @@
427
400
  },
428
401
  performance: {
429
402
  log: function (message) {
430
- var
431
- currentTime,
432
- executionTime,
433
- previousTime
434
- ;
403
+ let currentTime;
404
+ let executionTime;
405
+ let previousTime;
435
406
  if (settings.performance) {
436
407
  currentTime = Date.now();
437
408
  previousTime = time || currentTime;
@@ -450,10 +421,8 @@
450
421
  }, 500);
451
422
  },
452
423
  display: function () {
453
- var
454
- title = settings.name + ':',
455
- totalTime = 0
456
- ;
424
+ let title = settings.name + ':';
425
+ let totalTime = 0;
457
426
  time = false;
458
427
  clearTimeout(module.performance.timer);
459
428
  $.each(performance, function (index, data) {
@@ -478,22 +447,19 @@
478
447
  },
479
448
  },
480
449
  invoke: function (query, passedArguments, context) {
481
- var
482
- object = instance,
483
- maxDepth,
484
- found,
485
- response
486
- ;
450
+ let object = instance;
451
+ let maxDepth;
452
+ let found;
453
+ let response;
487
454
  passedArguments = passedArguments || queryArguments;
488
455
  context = context || element;
489
456
  if (typeof query === 'string' && object !== undefined) {
490
457
  query = query.split(/[ .]/);
491
458
  maxDepth = query.length - 1;
492
459
  $.each(query, function (depth, value) {
493
- var camelCaseValue = depth !== maxDepth
460
+ let camelCaseValue = depth !== maxDepth
494
461
  ? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
495
- : query
496
- ;
462
+ : query;
497
463
  if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
498
464
  object = object[camelCaseValue];
499
465
  } else if (object[camelCaseValue] !== undefined) {
@@ -646,31 +612,20 @@
646
612
 
647
613
  templates: {
648
614
  escape: function (string) {
649
- var
650
- badChars = /["'<>]/g,
651
- shouldEscape = /["&'<>]/,
652
- escape = {
653
- '<': '&lt;',
654
- '>': '&gt;',
655
- '"': '&quot;',
656
- "'": '&apos;',
657
- },
658
- escapedChar = function (chr) {
659
- return escape[chr];
660
- }
661
- ;
662
- if (shouldEscape.test(string)) {
663
- string = string.replace(/&(?![\d#a-z]{1,12};)/gi, '&amp;');
664
- string = string.replace(badChars, escapedChar);
665
- }
666
-
667
- return string;
615
+ const badChars = /["'<>]|&(?![\d#A-Za-z]{1,12};)/g;
616
+ const escape = {
617
+ '"': '&quot;',
618
+ '&': '&amp;',
619
+ "'": '&apos;',
620
+ '<': '&lt;',
621
+ '>': '&gt;',
622
+ };
623
+
624
+ return string.replace(badChars, (chr) => escape[chr]);
668
625
  },
669
626
  iframe: function (url, parameters) {
670
- var
671
- src = url,
672
- escape = $.fn.embed.settings.templates.escape
673
- ;
627
+ let src = url;
628
+ let escape = $.fn.embed.settings.templates.escape;
674
629
  if (parameters) {
675
630
  src += '?' + parameters;
676
631
  }
@@ -681,10 +636,8 @@
681
636
  + ' msallowFullScreen allowFullScreen></iframe>';
682
637
  },
683
638
  placeholder: function (image, icon, alt) {
684
- var
685
- html = '',
686
- escape = $.fn.embed.settings.templates.escape
687
- ;
639
+ let html = '';
640
+ let escape = $.fn.embed.settings.templates.escape;
688
641
  if (icon) {
689
642
  html += '<i class="' + escape(icon) + ' icon"></i>';
690
643
  }
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Embed
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Embed
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*
2
- * # Fomantic UI - 2.10.0-beta.6+42a411a
2
+ * # Fomantic UI - 2.10.0-beta.8+62e258f
3
3
  * https://github.com/fomantic/Fomantic-UI
4
4
  * https://fomantic-ui.com/
5
5
  *
@@ -8,4 +8,4 @@
8
8
  * https://opensource.org/licenses/MIT
9
9
  *
10
10
  */
11
- !function(C,e){"use strict";e=void 0!==e&&e.Math===Math?e:globalThis,C.fn.embed=function(h){var b,v=C(this),g=Date.now(),y=[],w=h,D="string"==typeof w,P=[].slice.call(arguments,1);return v.each(function(){var t=C.isPlainObject(h)?C.extend(!0,{},C.fn.embed.settings,h):C.extend({},C.fn.embed.settings),e=t.selector,o=t.className,a=t.sources,l=t.error,r=t.metadata,n=t.namespace,i=t.templates,c="."+n,d="module-"+n,u=C(this),s=(u.find(e.placeholder),u.find(e.icon),u.find(e.embed)),m=this,p=u.data(d),f={initialize:function(){f.debug("Initializing embed"),f.determine.autoplay(),f.create(),f.bind.events(),f.instantiate()},instantiate:function(){f.verbose("Storing instance of module",f),p=f,u.data(d,f)},destroy:function(){f.verbose("Destroying previous instance of embed"),f.reset(),u.removeData(d).off(c)},refresh:function(){f.verbose("Refreshing selector cache"),u.find(e.placeholder),u.find(e.icon),s=u.find(e.embed)},bind:{events:function(){f.has.placeholder()&&(f.debug("Adding placeholder events"),u.on("click"+c,e.placeholder,f.createAndShow).on("click"+c,e.icon,f.createAndShow))}},create:function(){f.get.placeholder()?f.createPlaceholder():f.createAndShow()},createPlaceholder:function(e){var o=f.get.icon(),n=f.get.alt();e=e||f.get.placeholder(),u.html(i.placeholder(e,o,n)),f.debug("Creating placeholder for embed",e,o,n)},createEmbed:function(e){f.refresh(),e=e||f.get.url(),s=C("<div/>").addClass(o.embed).html(f.generate.embed(e)).appendTo(u),t.onCreate.call(m,e),f.debug("Creating embed object",s)},changeEmbed:function(e){s.html(f.generate.embed(e))},createAndShow:function(){f.createEmbed(),f.show()},change:function(e,o,n){f.debug("Changing video to ",e,o,n),u.data(r.source,e).data(r.id,o),n?u.data(r.url,n):u.removeData(r.url),f.has.embed()?f.changeEmbed():f.create()},reset:function(){f.debug("Clearing embed and showing placeholder"),f.remove.data(),f.remove.active(),f.remove.embed(),f.showPlaceholder(),t.onReset.call(m)},show:function(){f.debug("Showing embed"),f.set.active(),t.onDisplay.call(m)},hide:function(){f.debug("Hiding embed"),f.showPlaceholder()},showPlaceholder:function(){f.debug("Showing placeholder image"),f.remove.active(),t.onPlaceholderDisplay.call(m)},get:{id:function(){return t.id||u.data(r.id)},placeholder:function(){return t.placeholder||u.data(r.placeholder)},alt:function(){return t.alt||u.data(r.alt)},icon:function(){return t.icon||(void 0!==u.data(r.icon)?u.data(r.icon):f.determine.icon())},source:function(e){return t.source||(void 0!==u.data(r.source)?u.data(r.source):f.determine.source())},type:function(){var e=f.get.source();return void 0!==a[e]&&a[e].type},url:function(){return t.url||(void 0!==u.data(r.url)?u.data(r.url):f.determine.url())}},determine:{autoplay:function(){f.should.autoplay()&&(t.autoplay=!0)},source:function(n){var t=!1;return(n=n||f.get.url())&&C.each(a,function(e,o){if(-1!==n.search(o.domain))return t=e,!1}),t},icon:function(){var e=f.get.source();return void 0!==a[e]&&a[e].icon},url:function(){var e=t.id||u.data(r.id),o=t.source||u.data(r.source),o=void 0!==a[o]&&a[o].url.replace("{id}",e);return o&&u.data(r.url,o),o}},set:{active:function(){u.addClass(o.active)}},remove:{data:function(){u.removeData(r.id).removeData(r.icon).removeData(r.placeholder).removeData(r.alt).removeData(r.source).removeData(r.url)},active:function(){u.removeClass(o.active)},embed:function(){s.empty()}},encode:{parameters:function(e){var o,n=[];for(o in e)n.push(encodeURIComponent(o)+"="+encodeURIComponent(e[o]));return n.join("&amp;")}},generate:{embed:function(e){f.debug("Generating embed html");var o,n=f.get.source();return(e=f.get.url(e))?(n=f.generate.parameters(n),o=i.iframe(e,n)):f.error(l.noURL,u),o},parameters:function(e,o){e=a[e]&&void 0!==a[e].parameters?a[e].parameters(t):{};return(o=o||t.parameters)&&(e=C.extend({},e,o)),e=t.onEmbed(e),f.encode.parameters(e)}},has:{embed:function(){return 0<s.length},placeholder:function(){return t.placeholder||u.data(r.placeholder)}},should:{autoplay:function(){return"auto"===t.autoplay?t.placeholder||void 0!==u.data(r.placeholder):t.autoplay}},is:{video:function(){return"video"===f.get.type()}},setting:function(e,o){if(f.debug("Changing setting",e,o),C.isPlainObject(e))C.extend(!0,t,e);else{if(void 0===o)return t[e];C.isPlainObject(t[e])?C.extend(!0,t[e],o):t[e]=o}},internal:function(e,o){if(C.isPlainObject(e))C.extend(!0,f,e);else{if(void 0===o)return f[e];f[e]=o}},debug:function(){!t.silent&&t.debug&&(t.performance?f.performance.log(arguments):(f.debug=Function.prototype.bind.call(console.info,console,t.name+":"),f.debug.apply(console,arguments)))},verbose:function(){!t.silent&&t.verbose&&t.debug&&(t.performance?f.performance.log(arguments):(f.verbose=Function.prototype.bind.call(console.info,console,t.name+":"),f.verbose.apply(console,arguments)))},error:function(){t.silent||(f.error=Function.prototype.bind.call(console.error,console,t.name+":"),f.error.apply(console,arguments))},performance:{log:function(e){var o,n;t.performance&&(n=(o=Date.now())-(g||o),g=o,y.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:m,"Execution Time":n})),clearTimeout(f.performance.timer),f.performance.timer=setTimeout(function(){f.performance.display()},500)},display:function(){var e=t.name+":",n=0;g=!1,clearTimeout(f.performance.timer),C.each(y,function(e,o){n+=o["Execution Time"]}),e+=" "+n+"ms",1<v.length&&(e+=" ("+v.length+")"),0<y.length&&(console.groupCollapsed(e),console.table?console.table(y):C.each(y,function(e,o){console.log(o.Name+": "+o["Execution Time"]+"ms")}),console.groupEnd()),y=[]}},invoke:function(t,e,o){var a,r,n,i,c=p;return e=e||P,o=o||m,"string"==typeof t&&void 0!==c&&(t=t.split(/[ .]/),a=t.length-1,C.each(t,function(e,o){var n=e!==a?o+t[e+1].charAt(0).toUpperCase()+t[e+1].slice(1):t;if(C.isPlainObject(c[n])&&e!==a)c=c[n];else{if(void 0!==c[n])return r=c[n],!1;{if(!C.isPlainObject(c[o])||e===a)return void 0!==c[o]?r=c[o]:f.error(l.method,t),!1;c=c[o]}}})),"function"==typeof(i=r)&&"number"!=typeof i.nodeType?n=r.apply(o,e):void 0!==r&&(n=r),Array.isArray(b)?b.push(n):void 0!==b?b=[b,n]:void 0!==n&&(b=n),r}};D?(void 0===p&&f.initialize(),f.invoke(w)):(void 0!==p&&p.invoke("destroy"),f.initialize())}),void 0!==b?b:this},C.fn.embed.settings={name:"Embed",namespace:"embed",silent:!1,debug:!1,verbose:!1,performance:!0,icon:!1,source:!1,url:!1,id:!1,placeholder:!1,alt:!1,autoplay:"auto",color:"#444",hd:!0,brandedUI:!1,parameters:!1,onDisplay:function(){},onPlaceholderDisplay:function(){},onReset:function(){},onCreate:function(e){},onEmbed:function(e){return e},metadata:{id:"id",icon:"icon",placeholder:"placeholder",alt:"alt",source:"source",url:"url"},error:{noURL:"No URL specified",method:"The method you called is not defined"},className:{active:"active",embed:"embed"},selector:{embed:".embed",placeholder:".placeholder",icon:".icon"},sources:{youtube:{name:"youtube",type:"video",icon:"video play",domain:"youtube.com",url:"//www.youtube.com/embed/{id}",parameters:function(e){return{autohide:!e.brandedUI,autoplay:e.autoplay,color:e.color||void 0,hq:e.hd,jsapi:e.api,modestbranding:!e.brandedUI}}},vimeo:{name:"vimeo",type:"video",icon:"video play",domain:"vimeo.com",url:"//player.vimeo.com/video/{id}",parameters:function(e){return{api:e.api,autoplay:e.autoplay,byline:e.brandedUI,color:e.color||void 0,portrait:e.brandedUI,title:e.brandedUI}}}},templates:{escape:function(e){var o={"<":"&lt;",">":"&gt;",'"':"&quot;","'":"&apos;"};return e=/["&'<>]/.test(e)?(e=e.replace(/&(?![\d#a-z]{1,12};)/gi,"&amp;")).replace(/["'<>]/g,function(e){return o[e]}):e},iframe:function(e,o){return o&&(e+="?"+o),'<iframe src="'+(0,C.fn.embed.settings.templates.escape)(e)+'" width="100%" height="100%" msallowFullScreen allowFullScreen></iframe>'},placeholder:function(e,o,n){var t="",a=C.fn.embed.settings.templates.escape;return o&&(t+='<i class="'+a(o)+' icon"></i>'),e&&(t+='<img class="placeholder" src="'+a(e)+'"'+(n?' alt="'+a(n)+'"':"")+">"),t}},api:!1,onPause:function(){},onPlay:function(){},onStop:function(){}}}(jQuery,window,document);
11
+ !function(U,e){"use strict";e=void 0!==e&&e.Math===Math?e:globalThis,U.fn.embed=function(v){let g=U(this),y=Date.now(),w=[],D=v,P="string"==typeof D,C=[].slice.call(arguments,1),E;return g.each(function(){let t=U.isPlainObject(v)?U.extend(!0,{},U.fn.embed.settings,v):U.extend({},U.fn.embed.settings),e=t.selector,o=t.className,a=t.sources,l=t.error,r=t.metadata;var n=t.namespace;let i=t.templates,c="."+n,d="module-"+n,u=U(this),s=void u.find(e.placeholder),m=void u.find(e.icon),p=u.find(e.embed),f=this,h=u.data(d),b;b={initialize:function(){b.debug("Initializing embed"),b.determine.autoplay(),b.create(),b.bind.events(),b.instantiate()},instantiate:function(){b.verbose("Storing instance of module",b),h=b,u.data(d,b)},destroy:function(){b.verbose("Destroying previous instance of embed"),b.reset(),u.removeData(d).off(c)},refresh:function(){b.verbose("Refreshing selector cache"),s=u.find(e.placeholder),m=u.find(e.icon),p=u.find(e.embed)},bind:{events:function(){b.has.placeholder()&&(b.debug("Adding placeholder events"),u.on("click"+c,e.placeholder,b.createAndShow).on("click"+c,e.icon,b.createAndShow))}},create:function(){b.get.placeholder()?b.createPlaceholder():b.createAndShow()},createPlaceholder:function(e){var o=b.get.icon(),n=b.get.alt();e=e||b.get.placeholder(),u.html(i.placeholder(e,o,n)),b.debug("Creating placeholder for embed",e,o,n)},createEmbed:function(e){b.refresh(),e=e||b.get.url(),p=U("<div/>").addClass(o.embed).html(b.generate.embed(e)).appendTo(u),t.onCreate.call(f,e),b.debug("Creating embed object",p)},changeEmbed:function(e){p.html(b.generate.embed(e))},createAndShow:function(){b.createEmbed(),b.show()},change:function(e,o,n){b.debug("Changing video to ",e,o,n),u.data(r.source,e).data(r.id,o),n?u.data(r.url,n):u.removeData(r.url),b.has.embed()?b.changeEmbed():b.create()},reset:function(){b.debug("Clearing embed and showing placeholder"),b.remove.data(),b.remove.active(),b.remove.embed(),b.showPlaceholder(),t.onReset.call(f)},show:function(){b.debug("Showing embed"),b.set.active(),t.onDisplay.call(f)},hide:function(){b.debug("Hiding embed"),b.showPlaceholder()},showPlaceholder:function(){b.debug("Showing placeholder image"),b.remove.active(),t.onPlaceholderDisplay.call(f)},get:{id:function(){return t.id||u.data(r.id)},placeholder:function(){return t.placeholder||u.data(r.placeholder)},alt:function(){return t.alt||u.data(r.alt)},icon:function(){return t.icon||(void 0!==u.data(r.icon)?u.data(r.icon):b.determine.icon())},source:function(e){return t.source||(void 0!==u.data(r.source)?u.data(r.source):b.determine.source())},type:function(){var e=b.get.source();return void 0!==a[e]&&a[e].type},url:function(){return t.url||(void 0!==u.data(r.url)?u.data(r.url):b.determine.url())}},determine:{autoplay:function(){b.should.autoplay()&&(t.autoplay=!0)},source:function(n){let t=!1;return(n=n||b.get.url())&&U.each(a,function(e,o){if(-1!==n.search(o.domain))return t=e,!1}),t},icon:function(){var e=b.get.source();return void 0!==a[e]&&a[e].icon},url:function(){var e=t.id||u.data(r.id),o=t.source||u.data(r.source),o=void 0!==a[o]&&a[o].url.replace("{id}",e);return o&&u.data(r.url,o),o}},set:{active:function(){u.addClass(o.active)}},remove:{data:function(){u.removeData(r.id).removeData(r.icon).removeData(r.placeholder).removeData(r.alt).removeData(r.source).removeData(r.url)},active:function(){u.removeClass(o.active)},embed:function(){p.empty()}},encode:{parameters:function(e){let o=[],n;for(n in e)o.push(encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return o.join("&amp;")}},generate:{embed:function(e){b.debug("Generating embed html");var o=b.get.source();let n;return(e=b.get.url(e))?(o=b.generate.parameters(o),n=i.iframe(e,o)):b.error(l.noURL,u),n},parameters:function(e,o){let n=a[e]&&void 0!==a[e].parameters?a[e].parameters(t):{};return(o=o||t.parameters)&&(n=U.extend({},n,o)),n=t.onEmbed(n),b.encode.parameters(n)}},has:{embed:function(){return 0<p.length},placeholder:function(){return t.placeholder||u.data(r.placeholder)}},should:{autoplay:function(){return"auto"===t.autoplay?t.placeholder||void 0!==u.data(r.placeholder):t.autoplay}},is:{video:function(){return"video"===b.get.type()}},setting:function(e,o){if(b.debug("Changing setting",e,o),U.isPlainObject(e))U.extend(!0,t,e);else{if(void 0===o)return t[e];U.isPlainObject(t[e])?U.extend(!0,t[e],o):t[e]=o}},internal:function(e,o){if(U.isPlainObject(e))U.extend(!0,b,e);else{if(void 0===o)return b[e];b[e]=o}},debug:function(){!t.silent&&t.debug&&(t.performance?b.performance.log(arguments):(b.debug=Function.prototype.bind.call(console.info,console,t.name+":"),b.debug.apply(console,arguments)))},verbose:function(){!t.silent&&t.verbose&&t.debug&&(t.performance?b.performance.log(arguments):(b.verbose=Function.prototype.bind.call(console.info,console,t.name+":"),b.verbose.apply(console,arguments)))},error:function(){t.silent||(b.error=Function.prototype.bind.call(console.error,console,t.name+":"),b.error.apply(console,arguments))},performance:{log:function(e){var o,n;t.performance&&(n=(o=Date.now())-(y||o),y=o,w.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:f,"Execution Time":n})),clearTimeout(b.performance.timer),b.performance.timer=setTimeout(function(){b.performance.display()},500)},display:function(){let e=t.name+":",n=0;y=!1,clearTimeout(b.performance.timer),U.each(w,function(e,o){n+=o["Execution Time"]}),e+=" "+n+"ms",1<g.length&&(e+=" ("+g.length+")"),0<w.length&&(console.groupCollapsed(e),console.table?console.table(w):U.each(w,function(e,o){console.log(o.Name+": "+o["Execution Time"]+"ms")}),console.groupEnd()),w=[]}},invoke:function(t,e,o){let a=h,r,i,n;var c;return e=e||C,o=o||f,"string"==typeof t&&void 0!==a&&(t=t.split(/[ .]/),r=t.length-1,U.each(t,function(e,o){var n=e!==r?o+t[e+1].charAt(0).toUpperCase()+t[e+1].slice(1):t;if(U.isPlainObject(a[n])&&e!==r)a=a[n];else{if(void 0!==a[n])return i=a[n],!1;{if(!U.isPlainObject(a[o])||e===r)return void 0!==a[o]?i=a[o]:b.error(l.method,t),!1;a=a[o]}}})),"function"==typeof(c=i)&&"number"!=typeof c.nodeType?n=i.apply(o,e):void 0!==i&&(n=i),Array.isArray(E)?E.push(n):void 0!==E?E=[E,n]:void 0!==n&&(E=n),i}},P?(void 0===h&&b.initialize(),b.invoke(D)):(void 0!==h&&h.invoke("destroy"),b.initialize())}),void 0!==E?E:this},U.fn.embed.settings={name:"Embed",namespace:"embed",silent:!1,debug:!1,verbose:!1,performance:!0,icon:!1,source:!1,url:!1,id:!1,placeholder:!1,alt:!1,autoplay:"auto",color:"#444",hd:!0,brandedUI:!1,parameters:!1,onDisplay:function(){},onPlaceholderDisplay:function(){},onReset:function(){},onCreate:function(e){},onEmbed:function(e){return e},metadata:{id:"id",icon:"icon",placeholder:"placeholder",alt:"alt",source:"source",url:"url"},error:{noURL:"No URL specified",method:"The method you called is not defined"},className:{active:"active",embed:"embed"},selector:{embed:".embed",placeholder:".placeholder",icon:".icon"},sources:{youtube:{name:"youtube",type:"video",icon:"video play",domain:"youtube.com",url:"//www.youtube.com/embed/{id}",parameters:function(e){return{autohide:!e.brandedUI,autoplay:e.autoplay,color:e.color||void 0,hq:e.hd,jsapi:e.api,modestbranding:!e.brandedUI}}},vimeo:{name:"vimeo",type:"video",icon:"video play",domain:"vimeo.com",url:"//player.vimeo.com/video/{id}",parameters:function(e){return{api:e.api,autoplay:e.autoplay,byline:e.brandedUI,color:e.color||void 0,portrait:e.brandedUI,title:e.brandedUI}}}},templates:{escape:function(e){const o={'"':"&quot;","&":"&amp;","'":"&apos;","<":"&lt;",">":"&gt;"};return e.replace(/["'<>]|&(?![\d#A-Za-z]{1,12};)/g,e=>o[e])},iframe:function(e,o){let n=e,t=U.fn.embed.settings.templates.escape;return o&&(n+="?"+o),'<iframe src="'+t(n)+'" width="100%" height="100%" msallowFullScreen allowFullScreen></iframe>'},placeholder:function(e,o,n){let t="",a=U.fn.embed.settings.templates.escape;return o&&(t+='<i class="'+a(o)+' icon"></i>'),e&&(t+='<img class="placeholder" src="'+a(e)+'"'+(n?' alt="'+a(n)+'"':"")+">"),t}},api:!1,onPause:function(){},onPlay:function(){},onStop:function(){}}}(jQuery,window,document);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Emoji
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Emoji
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Emoji
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Emoji
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Feed
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Feed
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Feed
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Feed
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Flag
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Flag
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Flag
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Flag
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Flyout
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Flyout
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *