@spaced-out/ui-design-system 0.1.23 → 0.1.24

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,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.1.24](https://github.com/spaced-out/ui-design-system/compare/v0.1.23...v0.1.24) (2023-04-26)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * avatar image fit to center ([#107](https://github.com/spaced-out/ui-design-system/issues/107)) ([e9ceec0](https://github.com/spaced-out/ui-design-system/commit/e9ceec04b61e96182f32fbad24f45a681399c9d8))
11
+
5
12
  ### [0.1.23](https://github.com/spaced-out/ui-design-system/compare/v0.1.22...v0.1.23) (2023-04-26)
6
13
 
7
14
 
@@ -80,7 +80,9 @@ const AvatarConditionalContent = _ref2 => {
80
80
  classNames
81
81
  } = _ref2;
82
82
  return /*#__PURE__*/React.createElement("div", {
83
- className: (0, _classify.default)(_AvatarModule.default.innerContainer, classNames?.content),
83
+ className: (0, _classify.default)(_AvatarModule.default.innerContainer, {
84
+ [_AvatarModule.default.alignCenter]: !imageSrc
85
+ }, classNames?.content),
84
86
  style: {
85
87
  '--background-color': AVATAR_COLOR[color]
86
88
  }
@@ -129,7 +129,11 @@ const AvatarConditionalContent = ({
129
129
  classNames,
130
130
  }: AvatarContentProps) => (
131
131
  <div
132
- className={classify(css.innerContainer, classNames?.content)}
132
+ className={classify(
133
+ css.innerContainer,
134
+ {[css.alignCenter]: !imageSrc},
135
+ classNames?.content,
136
+ )}
133
137
  style={{
134
138
  '--background-color': AVATAR_COLOR[color],
135
139
  }}
@@ -54,12 +54,13 @@
54
54
 
55
55
  .avatar {
56
56
  vertical-align: middle;
57
- max-width: sizeFluid;
58
- max-height: sizeFluid;
57
+ min-width: sizeFluid;
58
+ min-height: sizeFluid;
59
59
  border-radius: borderRadiusCircle;
60
60
  display: flex;
61
61
  align-items: center;
62
62
  justify-content: center;
63
+ object-fit: cover;
63
64
  }
64
65
 
65
66
  .ring {
@@ -90,9 +91,12 @@
90
91
  border-radius: borderRadiusCircle;
91
92
  width: sizeFluid;
92
93
  height: sizeFluid;
94
+ background: var(--background-color);
95
+ }
96
+
97
+ .alignCenter {
93
98
  align-items: center;
94
99
  justify-content: center;
95
- background: var(--background-color);
96
100
  }
97
101
 
98
102
  .statusIndicatorWrapper {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spaced-out/ui-design-system",
3
- "version": "0.1.23",
3
+ "version": "0.1.24",
4
4
  "main": "index.js",
5
5
  "description": "Sense UI components library",
6
6
  "author": {