@doodl/slate 1.23.4 → 1.23.5

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,18 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
4
4
 
5
+ ### [1.23.5](https://bitbucket.org/doodlltd/slate/compare/v1.23.4...v1.23.5) (2024-07-24)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * fix float rules for images added via SilverStripe's CMS editor ([895be6e](https://bitbucket.org/doodlltd/slate/commit/895be6ec0c58b17b6ca3c79cb4622725814a1fcc))
11
+
12
+
13
+ ### Improvements
14
+
15
+ * add an option to explicitly force an image to float on small screen sizes ([1a0acb2](https://bitbucket.org/doodlltd/slate/commit/1a0acb2c94f76c9b48d6eb6fa84e54633ad2143c))
16
+
5
17
  ### [1.23.4](https://bitbucket.org/doodlltd/slate/compare/v1.23.3...v1.23.4) (2024-07-23)
6
18
 
7
19
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@doodl/slate",
3
- "version": "1.23.4",
3
+ "version": "1.23.5",
4
4
  "description": "",
5
5
  "main": "./js/dist/index.js",
6
6
  "module": "./js/dist/index.js",
@@ -43,20 +43,26 @@
43
43
  margin: $slate-silverstripe-editor-image-floated-margin-top auto
44
44
  $slate-silverstripe-editor-image-floated-margin-bottom;
45
45
 
46
- &.left {
47
- float: left;
48
- margin-right: $slate-silverstripe-editor-image-floated-margin-horizontal;
49
- margin-left: 0;
50
- }
51
-
52
- &.right {
53
- float: right;
54
- margin-right: 0;
55
- margin-left: $slate-silverstripe-editor-image-floated-margin-horizontal;
46
+ @mixin float-rules {
47
+ &.left {
48
+ float: left;
49
+ margin-right: $slate-silverstripe-editor-image-floated-margin-horizontal;
50
+ margin-left: 0;
51
+ }
52
+
53
+ &.right {
54
+ float: right;
55
+ margin-right: 0;
56
+ margin-left: $slate-silverstripe-editor-image-floated-margin-horizontal;
57
+ }
58
+
59
+ &.rightAlone {
60
+ margin-right: 0;
61
+ }
56
62
  }
57
63
 
58
- &.rightAlone {
59
- margin-right: 0;
64
+ &.force-float-small {
65
+ @include float-rules;
60
66
  }
61
67
 
62
68
  // Center up the images on mobile so the text doesn't get squeezed out
@@ -64,6 +70,7 @@
64
70
  @include align-all {
65
71
  max-width: $slate-silverstripe-editor-image-max-width;
66
72
  }
73
+ @include float-rules;
67
74
  }
68
75
  }
69
76