@gitlab/ui 32.64.0 → 32.66.0

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 (50) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist/components/base/paginated_list/paginated_list.documentation.js +2 -5
  3. package/dist/components/base/toast/toast.documentation.js +2 -5
  4. package/dist/components/utilities/intersection_observer/intersection_observer.documentation.js +1 -20
  5. package/dist/components/utilities/intersection_observer/intersection_observer.js +12 -0
  6. package/dist/utility_classes.css +1 -1
  7. package/dist/utility_classes.css.map +1 -1
  8. package/documentation/documented_stories.js +3 -0
  9. package/package.json +1 -1
  10. package/src/components/base/paginated_list/paginated_list.documentation.js +0 -2
  11. package/src/components/base/paginated_list/paginated_list.md +0 -2
  12. package/src/components/base/paginated_list/paginated_list.stories.js +162 -154
  13. package/src/components/base/toast/toast.documentation.js +0 -2
  14. package/src/components/base/toast/toast.md +0 -11
  15. package/src/components/base/toast/toast.stories.js +66 -50
  16. package/src/components/utilities/intersection_observer/intersection_observer.documentation.js +0 -23
  17. package/src/components/utilities/intersection_observer/intersection_observer.stories.js +91 -80
  18. package/src/components/utilities/intersection_observer/intersection_observer.vue +15 -0
  19. package/src/scss/utilities.scss +30 -4
  20. package/src/scss/utility-mixins/flex.scss +1 -1
  21. package/src/scss/utility-mixins/opacity.scss +8 -0
  22. package/src/scss/utility-mixins/spacing.scss +7 -1
  23. package/dist/components/base/paginated_list/examples/index.js +0 -49
  24. package/dist/components/base/paginated_list/examples/paginated_list.basic.example.js +0 -51
  25. package/dist/components/base/paginated_list/examples/paginated_list.no_filter.example.js +0 -51
  26. package/dist/components/base/paginated_list/examples/paginated_list.with_empty_list.example.js +0 -38
  27. package/dist/components/base/paginated_list/examples/paginated_list.with_filter_function.example.js +0 -51
  28. package/dist/components/base/paginated_list/examples/paginated_list.with_header_slot.example.js +0 -51
  29. package/dist/components/base/paginated_list/examples/paginated_list.with_row_slot.example.js +0 -53
  30. package/dist/components/base/paginated_list/examples/paginated_list.with_subheader_slot.example.js +0 -51
  31. package/dist/components/base/toast/examples/index.js +0 -19
  32. package/dist/components/base/toast/examples/toast.action.example.js +0 -40
  33. package/dist/components/base/toast/examples/toast.default.example.js +0 -38
  34. package/dist/components/utilities/intersection_observer/examples/index.js +0 -19
  35. package/dist/components/utilities/intersection_observer/examples/intersection_observer.image.example.js +0 -62
  36. package/dist/components/utilities/intersection_observer/examples/intersection_observer.last_appeared.example.js +0 -83
  37. package/src/components/base/paginated_list/examples/index.js +0 -57
  38. package/src/components/base/paginated_list/examples/paginated_list.basic.example.vue +0 -19
  39. package/src/components/base/paginated_list/examples/paginated_list.no_filter.example.vue +0 -20
  40. package/src/components/base/paginated_list/examples/paginated_list.with_empty_list.example.vue +0 -3
  41. package/src/components/base/paginated_list/examples/paginated_list.with_filter_function.example.vue +0 -20
  42. package/src/components/base/paginated_list/examples/paginated_list.with_header_slot.example.vue +0 -23
  43. package/src/components/base/paginated_list/examples/paginated_list.with_row_slot.example.vue +0 -25
  44. package/src/components/base/paginated_list/examples/paginated_list.with_subheader_slot.example.vue +0 -23
  45. package/src/components/base/toast/examples/index.js +0 -22
  46. package/src/components/base/toast/examples/toast.action.example.vue +0 -11
  47. package/src/components/base/toast/examples/toast.default.example.vue +0 -3
  48. package/src/components/utilities/intersection_observer/examples/index.js +0 -23
  49. package/src/components/utilities/intersection_observer/examples/intersection_observer.image.example.vue +0 -29
  50. package/src/components/utilities/intersection_observer/examples/intersection_observer.last_appeared.example.vue +0 -43
@@ -1,43 +0,0 @@
1
- <script>
2
- export default {
3
- data: () => ({
4
- appearedAt: null,
5
- now: null,
6
- interval: null,
7
- }),
8
- computed: {
9
- secondsSinceAppearance() {
10
- if (!this.appearedAt) {
11
- return 0;
12
- }
13
- return Math.floor((this.now - this.appearedAt) / 1000);
14
- },
15
- },
16
- destroyed() {
17
- this.clearInterval();
18
- },
19
- methods: {
20
- appear() {
21
- this.clearInterval();
22
- this.interval = setInterval(this.tick, 1000);
23
- this.tick();
24
- this.appearedAt = this.now;
25
- },
26
- disappear() {
27
- this.clearInterval();
28
- },
29
- clearInterval() {
30
- clearInterval(this.interval);
31
- },
32
- tick() {
33
- this.now = new Date().getTime();
34
- },
35
- },
36
- };
37
- </script>
38
-
39
- <template>
40
- <gl-intersection-observer @appear="appear" @disappear="disappear">
41
- <span>Last appeared {{ secondsSinceAppearance }} seconds ago</span>
42
- </gl-intersection-observer>
43
- </template>