pages_core 3.12.0 → 3.12.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (199) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/app/assets/builds/fonts/661557ef.ttf +0 -0
  4. data/app/assets/builds/fonts/a18fc2d2.woff2 +0 -0
  5. data/app/assets/builds/fonts/b2c7b78f.woff2 +0 -0
  6. data/app/assets/builds/fonts/ceddc204.ttf +0 -0
  7. data/app/assets/builds/pages_core/admin-dist.js +60 -14
  8. data/app/assets/builds/pages_core/admin-dist.js.map +7 -0
  9. data/app/assets/builds/pages_core/admin.css +9272 -0
  10. data/app/assets/images/pages/admin/angle-down-solid.svg +1 -0
  11. data/app/assets/images/pages/admin/icon.svg +1 -0
  12. data/app/assets/stylesheets/pages_core/admin/components/archive.css +6 -0
  13. data/app/assets/stylesheets/{pages/admin/components/attachments.scss → pages_core/admin/components/attachments.css} +35 -28
  14. data/app/assets/stylesheets/{pages/admin.scss → pages_core/admin/components/base.css} +125 -123
  15. data/app/assets/stylesheets/pages_core/admin/components/forms.css +223 -0
  16. data/app/assets/stylesheets/{pages/admin/components/header.scss → pages_core/admin/components/header.css} +76 -46
  17. data/app/assets/stylesheets/{pages/admin/components/image_editor.scss → pages_core/admin/components/image_editor.css} +42 -31
  18. data/app/assets/stylesheets/{pages/admin/components/image_grid.scss → pages_core/admin/components/image_grid.css} +76 -64
  19. data/app/assets/stylesheets/{pages/admin/components/image_uploader.scss → pages_core/admin/components/image_uploader.css} +12 -12
  20. data/app/assets/stylesheets/{pages/admin/components/layout.scss → pages_core/admin/components/layout.css} +13 -9
  21. data/app/assets/stylesheets/pages_core/admin/components/links.css +40 -0
  22. data/app/assets/stylesheets/pages_core/admin/components/list_table.css +66 -0
  23. data/app/assets/stylesheets/{pages/admin/components/login.scss → pages_core/admin/components/login.css} +6 -5
  24. data/app/assets/stylesheets/{pages/admin/components/modal.scss → pages_core/admin/components/modal.css} +10 -12
  25. data/app/assets/stylesheets/{pages/admin/components/page_tree.scss → pages_core/admin/components/page_tree.css} +54 -55
  26. data/app/assets/stylesheets/{pages/admin/components/pagination.scss → pages_core/admin/components/pagination.css} +17 -17
  27. data/app/assets/stylesheets/pages_core/admin/components/search.css +27 -0
  28. data/app/assets/stylesheets/{pages/admin/components/sidebar.scss → pages_core/admin/components/sidebar.css} +8 -7
  29. data/app/assets/stylesheets/{pages/admin/components/tag_editor.scss → pages_core/admin/components/tag_editor.css} +10 -15
  30. data/app/assets/stylesheets/{pages/admin/components/textarea.scss → pages_core/admin/components/textarea.css} +1 -1
  31. data/app/assets/stylesheets/{pages/admin/components/toast.scss → pages_core/admin/components/toast.css} +5 -3
  32. data/app/assets/stylesheets/{pages/admin/components/toolbar.scss → pages_core/admin/components/toolbar.css} +56 -29
  33. data/app/assets/stylesheets/{pages/admin/controllers/pages.scss → pages_core/admin/controllers/pages.css} +69 -52
  34. data/app/assets/stylesheets/pages_core/admin/controllers/users.css +3 -0
  35. data/app/assets/stylesheets/pages_core/admin/vars.css +34 -0
  36. data/app/assets/stylesheets/pages_core/admin.postcss.css +9 -0
  37. data/app/controllers/admin/pages_controller.rb +12 -11
  38. data/app/controllers/concerns/pages_core/rss_controller.rb +17 -1
  39. data/app/controllers/pages_core/admin_controller.rb +6 -0
  40. data/app/controllers/pages_core/frontend/pages_controller.rb +9 -5
  41. data/app/controllers/pages_core/sitemaps_controller.rb +3 -5
  42. data/app/formatters/pages_core/image_embedder.rb +5 -27
  43. data/app/helpers/admin/calendars_helper.rb +8 -0
  44. data/app/helpers/admin/news_helper.rb +13 -0
  45. data/app/helpers/admin/pages_helper.rb +32 -0
  46. data/app/helpers/pages_core/admin/admin_helper.rb +11 -54
  47. data/app/helpers/pages_core/admin/deprecated_admin_helper.rb +40 -0
  48. data/app/helpers/pages_core/images_helper.rb +37 -0
  49. data/app/javascript/admin-dist.ts +2 -0
  50. data/app/javascript/components/Attachments/{Attachment.jsx → Attachment.tsx} +44 -35
  51. data/app/javascript/components/Attachments/{AttachmentEditor.jsx → AttachmentEditor.tsx} +23 -23
  52. data/app/javascript/components/{EditableImage.jsx → EditableImage.tsx} +28 -25
  53. data/app/javascript/components/{FileUploadButton.jsx → FileUploadButton.tsx} +15 -16
  54. data/app/javascript/components/ImageCropper/FocalPoint.tsx +94 -0
  55. data/app/javascript/components/ImageCropper/{Image.jsx → Image.tsx} +13 -14
  56. data/app/javascript/components/ImageCropper/{Toolbar.jsx → Toolbar.tsx} +19 -15
  57. data/app/javascript/components/ImageCropper/{useCrop.js → useCrop.ts} +80 -37
  58. data/app/javascript/components/{ImageCropper.jsx → ImageCropper.tsx} +17 -15
  59. data/app/javascript/components/ImageEditor/{Form.jsx → Form.tsx} +24 -23
  60. data/app/javascript/components/{ImageEditor.jsx → ImageEditor.tsx} +17 -15
  61. data/app/javascript/components/ImageGrid/{DragElement.jsx → DragElement.tsx} +12 -10
  62. data/app/javascript/components/ImageGrid/{GridImage.jsx → GridImage.tsx} +40 -30
  63. data/app/javascript/components/ImageGrid/{Placeholder.jsx → Placeholder.tsx} +5 -6
  64. data/app/javascript/components/ImageGrid.jsx +3 -4
  65. data/app/javascript/components/{ImageUploader.jsx → ImageUploader.tsx} +46 -41
  66. data/app/javascript/components/Modal.tsx +48 -0
  67. data/app/javascript/components/PageImages.tsx +28 -0
  68. data/app/javascript/components/{PageTreeDraggable.jsx → PageTree/Draggable.tsx} +79 -57
  69. data/app/javascript/components/{PageTreeNode.jsx → PageTree/Node.tsx} +86 -77
  70. data/app/javascript/components/PageTree/types.ts +15 -0
  71. data/app/javascript/components/PageTree.tsx +206 -0
  72. data/app/javascript/components/RichTextToolbarButton.tsx +17 -0
  73. data/app/javascript/components/TagEditor/{AddTagForm.jsx → AddTagForm.tsx} +9 -10
  74. data/app/javascript/components/TagEditor/{Tag.jsx → Tag.tsx} +8 -9
  75. data/app/javascript/components/{TagEditor.jsx → TagEditor.tsx} +12 -13
  76. data/app/javascript/components/Toast.tsx +61 -0
  77. data/app/javascript/components/drag/{draggedOrder.js → draggedOrder.ts} +22 -12
  78. data/app/javascript/components/drag/types.ts +28 -0
  79. data/app/javascript/components/drag/{useDragCollection.js → useDragCollection.ts} +40 -22
  80. data/app/javascript/components/drag/{useDragUploader.js → useDragUploader.ts} +34 -25
  81. data/app/javascript/components/drag/useDraggable.ts +21 -0
  82. data/app/javascript/components/{drag.js → drag.ts} +1 -0
  83. data/app/javascript/controllers/{EditPageController.js → EditPageController.ts} +3 -1
  84. data/app/javascript/controllers/{LoginController.js → LoginController.ts} +7 -3
  85. data/app/javascript/controllers/{MainController.js → MainController.ts} +19 -14
  86. data/app/javascript/{index.js → index.ts} +8 -7
  87. data/app/javascript/lib/{Tree.js → Tree.ts} +106 -85
  88. data/app/javascript/lib/{copyToClipboard.js → copyToClipboard.ts} +1 -1
  89. data/app/javascript/lib/{readyHandler.js → readyHandler.ts} +4 -2
  90. data/app/javascript/lib/{request.js → request.ts} +11 -5
  91. data/app/javascript/stores/useModalStore.ts +15 -0
  92. data/app/javascript/stores/useToastStore.ts +26 -0
  93. data/app/javascript/stores.ts +2 -0
  94. data/app/javascript/types.ts +30 -0
  95. data/app/mailers/admin_mailer.rb +1 -0
  96. data/app/models/invite.rb +8 -0
  97. data/app/policies/page_policy.rb +4 -0
  98. data/app/views/admin/calendars/_sidebar.html.erb +50 -0
  99. data/app/views/admin/calendars/show.html.erb +15 -53
  100. data/app/views/admin/invites/new.html.erb +2 -8
  101. data/app/views/admin/invites/show.html.erb +2 -4
  102. data/app/views/admin/news/_sidebar.html.erb +51 -0
  103. data/app/views/admin/news/index.html.erb +21 -56
  104. data/app/views/admin/pages/_list_item.html.erb +4 -22
  105. data/app/views/admin/pages/_search_bar.html.erb +12 -0
  106. data/app/views/admin/pages/deleted.html.erb +10 -8
  107. data/app/views/admin/pages/edit.html.erb +20 -11
  108. data/app/views/admin/pages/index.html.erb +10 -8
  109. data/app/views/admin/pages/new.html.erb +10 -14
  110. data/app/views/admin/pages/search.html.erb +54 -0
  111. data/app/views/admin/password_resets/show.html.erb +3 -5
  112. data/app/views/admin/users/deactivated.html.erb +6 -7
  113. data/app/views/admin/users/edit.html.erb +7 -9
  114. data/app/views/admin/users/index.html.erb +3 -6
  115. data/app/views/admin/users/login.html.erb +4 -5
  116. data/app/views/admin/users/new.html.erb +2 -4
  117. data/app/views/admin/users/new_password.html.erb +4 -5
  118. data/app/views/admin/users/show.html.erb +11 -9
  119. data/app/views/errors/401.html.erb +2 -1
  120. data/app/views/errors/403.html.erb +2 -1
  121. data/app/views/errors/404.html.erb +1 -3
  122. data/app/views/errors/405.html.erb +2 -1
  123. data/app/views/errors/422.html.erb +2 -1
  124. data/app/views/errors/500.html.erb +2 -3
  125. data/app/views/feeds/pages.rss.builder +3 -9
  126. data/app/views/layouts/admin/_header.html.erb +1 -2
  127. data/app/views/layouts/admin/_page_header.html.erb +4 -4
  128. data/app/views/layouts/admin.html.erb +3 -3
  129. data/app/views/layouts/errors.html.erb +127 -4
  130. data/config/routes.rb +1 -0
  131. data/lib/pages_core/configuration/pages.rb +0 -1
  132. data/lib/pages_core/engine.rb +4 -3
  133. data/lib/pages_core.rb +0 -1
  134. data/lib/rails/generators/pages_core/frontend/frontend_generator.rb +33 -17
  135. data/lib/rails/generators/pages_core/frontend/templates/application.html.erb +0 -1
  136. data/lib/rails/generators/pages_core/frontend/templates/javascript/lib/gridOverlay.ts +40 -0
  137. data/lib/rails/generators/pages_core/frontend/templates/javascript/lib/responsiveEmbeds.ts +68 -0
  138. data/lib/rails/generators/pages_core/frontend/templates/postcss.config.js +17 -0
  139. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/application.postcss.css +4 -0
  140. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/components/base.css +24 -0
  141. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/components/layout.css +21 -0
  142. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/config.css +5 -0
  143. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/animation.css +5 -0
  144. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/colors.css +18 -0
  145. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/fonts.css +6 -0
  146. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/grid.css +65 -0
  147. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/typography.css +131 -0
  148. data/lib/rails/generators/pages_core/install/templates/pages_initializer.rb +0 -3
  149. metadata +104 -255
  150. data/app/assets/images/pages/admin/icon.png +0 -0
  151. data/app/assets/images/pages/admin/image-editor-bg.png +0 -0
  152. data/app/assets/images/pages/admin/list-table-pin-blue.gif +0 -0
  153. data/app/assets/images/pages/admin/list-table-pin-disabled.gif +0 -0
  154. data/app/assets/images/pages/admin/list-table-pin-green.gif +0 -0
  155. data/app/assets/images/pages/admin/list-table-pin-red.gif +0 -0
  156. data/app/assets/images/pages/admin/list-table-pin-yellow.gif +0 -0
  157. data/app/assets/images/pages/admin/loading-modal.gif +0 -0
  158. data/app/assets/images/pages/feed-icon-14x14.png +0 -0
  159. data/app/assets/stylesheets/pages/admin/components/archive.scss +0 -6
  160. data/app/assets/stylesheets/pages/admin/components/buttons.scss +0 -23
  161. data/app/assets/stylesheets/pages/admin/components/forms.scss +0 -169
  162. data/app/assets/stylesheets/pages/admin/components/links.scss +0 -43
  163. data/app/assets/stylesheets/pages/admin/components/list_table.scss +0 -61
  164. data/app/assets/stylesheets/pages/admin/controllers/users.scss +0 -3
  165. data/app/assets/stylesheets/pages/admin/mixins/breakpoints.scss +0 -21
  166. data/app/assets/stylesheets/pages/admin/mixins/clearfix.scss +0 -7
  167. data/app/assets/stylesheets/pages/admin/mixins/gradients.scss +0 -7
  168. data/app/assets/stylesheets/pages/admin/vars.scss +0 -30
  169. data/app/assets/stylesheets/pages/errors.css +0 -128
  170. data/app/javascript/admin-dist.js +0 -2
  171. data/app/javascript/components/ImageCropper/FocalPoint.jsx +0 -93
  172. data/app/javascript/components/Modal.jsx +0 -59
  173. data/app/javascript/components/PageImages.jsx +0 -25
  174. data/app/javascript/components/PageTree.jsx +0 -196
  175. data/app/javascript/components/RichTextToolbarButton.jsx +0 -20
  176. data/app/javascript/components/Toast.jsx +0 -72
  177. data/app/javascript/components/drag/useDraggable.js +0 -17
  178. data/app/javascript/stores/ModalStore.jsx +0 -12
  179. data/app/javascript/stores/ToastStore.jsx +0 -14
  180. data/app/javascript/stores.js +0 -2
  181. data/lib/rails/generators/pages_core/frontend/templates/javascript/lib/GridOverlay.js +0 -66
  182. data/lib/rails/generators/pages_core/frontend/templates/javascript/lib/ResponsiveEmbeds.js +0 -72
  183. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/application.sass.scss +0 -15
  184. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/components/base.scss +0 -12
  185. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/config.scss +0 -26
  186. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/framework/breakpoints.scss +0 -42
  187. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/framework/clearfix.scss +0 -7
  188. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/framework/fonts.scss +0 -32
  189. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/framework/grid.scss +0 -168
  190. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/framework/grid_overlay.scss +0 -44
  191. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/colors.scss +0 -8
  192. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/global/typography.scss +0 -90
  193. data/lib/rails/generators/pages_core/frontend/templates/stylesheets/vendor/normalize.css +0 -349
  194. data/vendor/assets/stylesheets/ReactCrop.css +0 -167
  195. /data/app/assets/stylesheets/{pages/admin/components/tabs.scss → pages_core/admin/components/tabs.css} +0 -0
  196. /data/app/javascript/components/Attachments/{Placeholder.jsx → Placeholder.tsx} +0 -0
  197. /data/app/javascript/components/ImageGrid/{FilePlaceholder.jsx → FilePlaceholder.tsx} +0 -0
  198. /data/app/javascript/{components.js → components.ts} +0 -0
  199. /data/app/javascript/{hooks.js → hooks.ts} +0 -0
@@ -1,168 +0,0 @@
1
- @use "sass:math";
2
-
3
- // ---- Defaults --------------------------------------------------------------
4
-
5
- $base-font-size: 16px !default;
6
-
7
- $grids : (default: (column-count: 12,
8
- column: 94px,
9
- gutter: 24px,
10
- padding: 24px),
11
- mobile: (column-count: 4,
12
- column: 60px,
13
- gutter: 16px,
14
- padding: 16px)) !default;
15
-
16
- $spacings: (1: 12px,
17
- 2: 24px,
18
- 4: 40px,
19
- 8: 80px) !default;
20
-
21
- // Uncomment to limit full width
22
- // $limit-width: 1600px !default;
23
-
24
-
25
- // ---- Grid and sizing -------------------------------------------------------
26
-
27
- @function grid-value($grid, $name) {
28
- @return map-get(map-get($grids, $grid), $name);
29
- }
30
-
31
- // Inner width: Size of $grid in px, excluding outer padding
32
- @function inner-width($grid: default) {
33
- @return (grid-value($grid, column-count) * grid-value($grid, column)) +
34
- ((grid-value($grid, column-count) - 1) * grid-value($grid, gutter));
35
- }
36
-
37
- // Full width in px including padding
38
- @function full-width($grid: default) {
39
- @return inner-width($grid) + (grid-value($grid, padding) * 2);
40
- }
41
-
42
- @function px-to-percent($size, $grid: default) {
43
- @return percentage(math.div($size, full-width($grid)));
44
- }
45
-
46
- @function px-to-vw($size, $grid: default) {
47
- @return (math.div($size, full-width($grid)) * 100) * 1vw;
48
- }
49
-
50
- @function relative-size($size-px, $container: 100%, $grid: default) {
51
- @if unit($container) == '%' {
52
- $container: (inner-width($grid) * math.div($container, 100%));
53
- }
54
- @if (unit($container) != "px") {
55
- $container: columns-px($container, $grid: $grid);
56
- }
57
- @return percentage(math.div($size-px, $container));
58
- }
59
-
60
- @function rem-calc($value, $grid: default) {
61
- @if unit($value) == "rem" {
62
- @return $value;
63
- }
64
-
65
- // Assume px for values without units
66
- @if unit($value) == "" {
67
- $value: $value * 1px;
68
- }
69
-
70
- // Convert percentage to px
71
- @if unit($value) == "%" {
72
- $value: full-width($grid) * math.div($value, 100%);
73
- }
74
-
75
- @return math.div($value, $base-font-size) * 1rem;
76
- }
77
-
78
- @function spacing($key) {
79
- @return rem-calc(map-get($spacings, $key));
80
- }
81
-
82
- // Width of gutter in px
83
- @function gutter-px($grid: default) {
84
- @return grid-value($grid, gutter);
85
- }
86
-
87
- // Width of $n columns in px
88
- @function columns-px($n: 1, $grid: default) {
89
- @return grid-value($grid, column) * $n + ((ceil($n) - 1) * gutter-px($grid));
90
- }
91
-
92
- // Gutter width, optionally relative to size of $container
93
- @function gutter($container: 100%, $grid: default) {
94
- @return relative-size(gutter-px($grid: $grid), $container, $grid: $grid);
95
- }
96
-
97
- // Width of $n columns as a percentage of $container.
98
- @function columns($n: 1, $container: 100%, $grid: default) {
99
- @return relative-size(columns-px($n, $grid: $grid), $container, $grid: $grid);
100
- }
101
-
102
- // Equal to columns($n) + gutter()
103
- @function columns-and-gutter($n: 1, $container: 100%, $grid: default) {
104
- @return columns($n, $container, $grid) + gutter($container, $grid);
105
- }
106
-
107
- @function grid-adjust($size, $columns: $total-columns, $grid: default) {
108
- @return math.div($sizem math.div(columns($columns, $grid: $grid), 100%));
109
- }
110
-
111
- @function outer-padding($grid: default) {
112
- @return px-to-percent(grid-value($grid, padding), $grid: $grid);
113
- }
114
-
115
- @function limit-width-scale($value) {
116
- @return $value * math.div($limit-width, full-width());
117
- }
118
-
119
-
120
- // ---- Styles ----------------------------------------------------------------
121
-
122
- @mixin mobile-full {
123
- @include mobile {
124
- width: 100%;
125
- margin-left: 0px;
126
- margin-right: 0px;
127
- float: none;
128
- @content;
129
- }
130
- }
131
-
132
- @mixin mobile-offset {
133
- @include mobile {
134
- $offset: px-to-percent(grid-value(mobile, padding), $grid: mobile);
135
-
136
- width: 100% + $offset;
137
- margin-left: 0 - math.div($offset, 2);
138
- margin-right: 0 - math.div($offset, 2);
139
- }
140
- }
141
-
142
- @mixin grid-container-inner {
143
- margin: 0px auto;
144
- @if variable-exists(limit-width) {
145
- @include breakpoint($min: rem-calc($limit-width)) {
146
- max-width: rem-calc(limit-width-scale(inner-width()));
147
- }
148
- }
149
- }
150
-
151
- @mixin grid-container {
152
- padding-left: outer-padding();
153
- padding-right: outer-padding();
154
-
155
- @include mobile {
156
- padding-left: outer-padding(mobile);
157
- padding-right: outer-padding(mobile);
158
- }
159
-
160
- @media print {
161
- padding-left: 0px;
162
- padding-right: 0px;
163
- }
164
-
165
- .inner {
166
- @include grid-container-inner;
167
- }
168
- }
@@ -1,44 +0,0 @@
1
- $grid-overlay-color: rgba(255, 0, 255, 0.05) !default;
2
-
3
- @function grid-background($grid: default) {
4
- $gradient: ();
5
- @for $i from 1 to grid-value($grid, column-count) {
6
- $gradient: join($gradient,
7
- ($grid-overlay-color columns($i, $grid: $grid),
8
- transparent columns($i, $grid: $grid),
9
- transparent columns-and-gutter($i, $grid: $grid),
10
- $grid-overlay-color (columns-and-gutter($i, $grid: $grid))),
11
- comma);
12
- }
13
- @return linear-gradient(to right, #{$gradient});
14
- }
15
-
16
- .grid-overlay {
17
- position: fixed;
18
- z-index: 9000;
19
- top: 0px;
20
- left: 0px;
21
- width: 100%;
22
- height: 100%;
23
- background-image: grid-background(default);
24
- background-size: px-to-percent(inner-width(default)) 100%;
25
- background-repeat: no-repeat;
26
- background-position: 50% 50%;
27
- pointer-events: none;
28
- display: none;
29
-
30
- @if variable-exists(limit-width) {
31
- @include breakpoint($min: rem-calc($limit-width)) {
32
- background-size: rem-calc(limit-width-scale(inner-width())) 100%;
33
- }
34
- }
35
-
36
- @include mobile {
37
- background-image: grid-background(mobile);
38
- background-size: px-to-percent(inner-width(mobile), $grid: mobile) 100%;
39
- }
40
-
41
- &--active {
42
- display: block;
43
- }
44
- }
@@ -1,8 +0,0 @@
1
- $colors: (background: #ffffff,
2
- text: #000000,
3
- text-light: #a1a1a1,
4
- border: #e0e0e0);
5
-
6
- @function color($name) {
7
- @return map-get($colors, $name);
8
- }
@@ -1,90 +0,0 @@
1
- $font-sans: 'Helvetica', sans-serif;
2
-
3
- // ---- Mixins ----------------------------------------------------------------
4
-
5
- @mixin child-margins {
6
- &:first-child {
7
- margin-top: 0px;
8
- }
9
- &:last-child {
10
- margin-bottom: 0px;
11
- }
12
- }
13
-
14
-
15
- // ---- Definitions -----------------------------------------------------------
16
-
17
- %text-larger { font: normal 72px/1.00 $font-sans; }
18
- %text-large { font: normal 54px/1.04 $font-sans; }
19
- %text-medium { font: normal 24px/1.25 $font-sans; }
20
- %text-normal { font: normal 16px/1.50 $font-sans; }
21
- %text-small { font: normal 14px/1.5 $font-sans; }
22
-
23
- @include mobile {
24
- %text-large { font: normal 32px/1.13 $font-sans; }
25
- %text-medium { font: normal 22px/1.27 $font-sans; }
26
- %text-normal { font: normal 16px/1.31 $font-sans; }
27
- %text-small-mobile,
28
- %text-small { font: normal 13px/1.31 $font-sans; }
29
- }
30
-
31
-
32
- // ---- Rules -----------------------------------------------------------------
33
-
34
- body {
35
- @extend %text-normal;
36
- }
37
-
38
- h1, h2, h3, h4, h5, h6, ul, ol, p {
39
- margin: 0px 0px spacing(2) 0px;
40
- &:last-child {
41
- margin-bottom: 0px;
42
- }
43
- }
44
-
45
- h1 {
46
- @extend %text-larger;
47
- }
48
-
49
- h2 {
50
- @extend %text-large;
51
- margin-top: spacing(10);
52
- margin-bottom: spacing(10);
53
- @include mobile {
54
- margin-top: spacing(5);
55
- margin-bottom: spacing(5);
56
- }
57
- @include child-margins;
58
- }
59
-
60
- h3 {
61
- @extend %text-medium;
62
- margin-top: spacing(5);
63
- margin-bottom: spacing(5);
64
- @include child-margins;
65
- }
66
-
67
- h4 {
68
- font: inherit;
69
- margin-top: spacing(5);
70
- margin-bottom: 0px;
71
- @include child-margins;
72
- }
73
-
74
- a, a:visited {
75
- text-decoration: underline;
76
- }
77
-
78
- h1, h2, h3 {
79
- a, a:visited {
80
- text-decoration: none;
81
- }
82
- a:hover, a:focus {
83
- text-decoration: underline;
84
- }
85
- }
86
-
87
- figcaption {
88
- @extend %text-small;
89
- margin-top: spacing(2);
90
- }
@@ -1,349 +0,0 @@
1
- /*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
2
-
3
- /* Document
4
- ========================================================================== */
5
-
6
- /**
7
- * 1. Correct the line height in all browsers.
8
- * 2. Prevent adjustments of font size after orientation changes in iOS.
9
- */
10
-
11
- html {
12
- line-height: 1.15; /* 1 */
13
- -webkit-text-size-adjust: 100%; /* 2 */
14
- }
15
-
16
- /* Sections
17
- ========================================================================== */
18
-
19
- /**
20
- * Remove the margin in all browsers.
21
- */
22
-
23
- body {
24
- margin: 0;
25
- }
26
-
27
- /**
28
- * Render the `main` element consistently in IE.
29
- */
30
-
31
- main {
32
- display: block;
33
- }
34
-
35
- /**
36
- * Correct the font size and margin on `h1` elements within `section` and
37
- * `article` contexts in Chrome, Firefox, and Safari.
38
- */
39
-
40
- h1 {
41
- font-size: 2em;
42
- margin: 0.67em 0;
43
- }
44
-
45
- /* Grouping content
46
- ========================================================================== */
47
-
48
- /**
49
- * 1. Add the correct box sizing in Firefox.
50
- * 2. Show the overflow in Edge and IE.
51
- */
52
-
53
- hr {
54
- box-sizing: content-box; /* 1 */
55
- height: 0; /* 1 */
56
- overflow: visible; /* 2 */
57
- }
58
-
59
- /**
60
- * 1. Correct the inheritance and scaling of font size in all browsers.
61
- * 2. Correct the odd `em` font sizing in all browsers.
62
- */
63
-
64
- pre {
65
- font-family: monospace, monospace; /* 1 */
66
- font-size: 1em; /* 2 */
67
- }
68
-
69
- /* Text-level semantics
70
- ========================================================================== */
71
-
72
- /**
73
- * Remove the gray background on active links in IE 10.
74
- */
75
-
76
- a {
77
- background-color: transparent;
78
- }
79
-
80
- /**
81
- * 1. Remove the bottom border in Chrome 57-
82
- * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
83
- */
84
-
85
- abbr[title] {
86
- border-bottom: none; /* 1 */
87
- text-decoration: underline; /* 2 */
88
- text-decoration: underline dotted; /* 2 */
89
- }
90
-
91
- /**
92
- * Add the correct font weight in Chrome, Edge, and Safari.
93
- */
94
-
95
- b,
96
- strong {
97
- font-weight: bolder;
98
- }
99
-
100
- /**
101
- * 1. Correct the inheritance and scaling of font size in all browsers.
102
- * 2. Correct the odd `em` font sizing in all browsers.
103
- */
104
-
105
- code,
106
- kbd,
107
- samp {
108
- font-family: monospace, monospace; /* 1 */
109
- font-size: 1em; /* 2 */
110
- }
111
-
112
- /**
113
- * Add the correct font size in all browsers.
114
- */
115
-
116
- small {
117
- font-size: 80%;
118
- }
119
-
120
- /**
121
- * Prevent `sub` and `sup` elements from affecting the line height in
122
- * all browsers.
123
- */
124
-
125
- sub,
126
- sup {
127
- font-size: 75%;
128
- line-height: 0;
129
- position: relative;
130
- vertical-align: baseline;
131
- }
132
-
133
- sub {
134
- bottom: -0.25em;
135
- }
136
-
137
- sup {
138
- top: -0.5em;
139
- }
140
-
141
- /* Embedded content
142
- ========================================================================== */
143
-
144
- /**
145
- * Remove the border on images inside links in IE 10.
146
- */
147
-
148
- img {
149
- border-style: none;
150
- }
151
-
152
- /* Forms
153
- ========================================================================== */
154
-
155
- /**
156
- * 1. Change the font styles in all browsers.
157
- * 2. Remove the margin in Firefox and Safari.
158
- */
159
-
160
- button,
161
- input,
162
- optgroup,
163
- select,
164
- textarea {
165
- font-family: inherit; /* 1 */
166
- font-size: 100%; /* 1 */
167
- line-height: 1.15; /* 1 */
168
- margin: 0; /* 2 */
169
- }
170
-
171
- /**
172
- * Show the overflow in IE.
173
- * 1. Show the overflow in Edge.
174
- */
175
-
176
- button,
177
- input { /* 1 */
178
- overflow: visible;
179
- }
180
-
181
- /**
182
- * Remove the inheritance of text transform in Edge, Firefox, and IE.
183
- * 1. Remove the inheritance of text transform in Firefox.
184
- */
185
-
186
- button,
187
- select { /* 1 */
188
- text-transform: none;
189
- }
190
-
191
- /**
192
- * Correct the inability to style clickable types in iOS and Safari.
193
- */
194
-
195
- button,
196
- [type="button"],
197
- [type="reset"],
198
- [type="submit"] {
199
- -webkit-appearance: button;
200
- }
201
-
202
- /**
203
- * Remove the inner border and padding in Firefox.
204
- */
205
-
206
- button::-moz-focus-inner,
207
- [type="button"]::-moz-focus-inner,
208
- [type="reset"]::-moz-focus-inner,
209
- [type="submit"]::-moz-focus-inner {
210
- border-style: none;
211
- padding: 0;
212
- }
213
-
214
- /**
215
- * Restore the focus styles unset by the previous rule.
216
- */
217
-
218
- button:-moz-focusring,
219
- [type="button"]:-moz-focusring,
220
- [type="reset"]:-moz-focusring,
221
- [type="submit"]:-moz-focusring {
222
- outline: 1px dotted ButtonText;
223
- }
224
-
225
- /**
226
- * Correct the padding in Firefox.
227
- */
228
-
229
- fieldset {
230
- padding: 0.35em 0.75em 0.625em;
231
- }
232
-
233
- /**
234
- * 1. Correct the text wrapping in Edge and IE.
235
- * 2. Correct the color inheritance from `fieldset` elements in IE.
236
- * 3. Remove the padding so developers are not caught out when they zero out
237
- * `fieldset` elements in all browsers.
238
- */
239
-
240
- legend {
241
- box-sizing: border-box; /* 1 */
242
- color: inherit; /* 2 */
243
- display: table; /* 1 */
244
- max-width: 100%; /* 1 */
245
- padding: 0; /* 3 */
246
- white-space: normal; /* 1 */
247
- }
248
-
249
- /**
250
- * Add the correct vertical alignment in Chrome, Firefox, and Opera.
251
- */
252
-
253
- progress {
254
- vertical-align: baseline;
255
- }
256
-
257
- /**
258
- * Remove the default vertical scrollbar in IE 10+.
259
- */
260
-
261
- textarea {
262
- overflow: auto;
263
- }
264
-
265
- /**
266
- * 1. Add the correct box sizing in IE 10.
267
- * 2. Remove the padding in IE 10.
268
- */
269
-
270
- [type="checkbox"],
271
- [type="radio"] {
272
- box-sizing: border-box; /* 1 */
273
- padding: 0; /* 2 */
274
- }
275
-
276
- /**
277
- * Correct the cursor style of increment and decrement buttons in Chrome.
278
- */
279
-
280
- [type="number"]::-webkit-inner-spin-button,
281
- [type="number"]::-webkit-outer-spin-button {
282
- height: auto;
283
- }
284
-
285
- /**
286
- * 1. Correct the odd appearance in Chrome and Safari.
287
- * 2. Correct the outline style in Safari.
288
- */
289
-
290
- [type="search"] {
291
- -webkit-appearance: textfield; /* 1 */
292
- outline-offset: -2px; /* 2 */
293
- }
294
-
295
- /**
296
- * Remove the inner padding in Chrome and Safari on macOS.
297
- */
298
-
299
- [type="search"]::-webkit-search-decoration {
300
- -webkit-appearance: none;
301
- }
302
-
303
- /**
304
- * 1. Correct the inability to style clickable types in iOS and Safari.
305
- * 2. Change font properties to `inherit` in Safari.
306
- */
307
-
308
- ::-webkit-file-upload-button {
309
- -webkit-appearance: button; /* 1 */
310
- font: inherit; /* 2 */
311
- }
312
-
313
- /* Interactive
314
- ========================================================================== */
315
-
316
- /*
317
- * Add the correct display in Edge, IE 10+, and Firefox.
318
- */
319
-
320
- details {
321
- display: block;
322
- }
323
-
324
- /*
325
- * Add the correct display in all browsers.
326
- */
327
-
328
- summary {
329
- display: list-item;
330
- }
331
-
332
- /* Misc
333
- ========================================================================== */
334
-
335
- /**
336
- * Add the correct display in IE 10+.
337
- */
338
-
339
- template {
340
- display: none;
341
- }
342
-
343
- /**
344
- * Add the correct display in IE 10.
345
- */
346
-
347
- [hidden] {
348
- display: none;
349
- }