@atlaskit/emoji 69.10.19 → 69.10.20
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 +8 -0
- package/dist/cjs/api/EmojiUtils.js +18 -3
- package/dist/cjs/util/analytics/analytics.js +1 -1
- package/dist/es2019/api/EmojiUtils.js +18 -3
- package/dist/es2019/util/analytics/analytics.js +1 -1
- package/dist/esm/api/EmojiUtils.js +18 -3
- package/dist/esm/util/analytics/analytics.js +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/emoji
|
|
2
2
|
|
|
3
|
+
## 69.10.20
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`de02dc0a51052`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/de02dc0a51052) -
|
|
8
|
+
[ux] [EDITOR-4986] change default emoji size to XXXHDPI
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 69.10.19
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -8,6 +8,7 @@ exports.shouldUseAltRepresentation = exports.isMediaApiUrl = exports.getPixelRat
|
|
|
8
8
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
10
10
|
var _utilServiceSupport = require("@atlaskit/util-service-support");
|
|
11
|
+
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
11
12
|
var _typeHelpers = require("../util/type-helpers");
|
|
12
13
|
var _logger = _interopRequireDefault(require("../util/logger"));
|
|
13
14
|
var _excluded = ["getRatio"],
|
|
@@ -33,6 +34,20 @@ var emojiRequest = exports.emojiRequest = function emojiRequest(provider, option
|
|
|
33
34
|
return _utilServiceSupport.utils.requestService(serviceConfig, requestOptions);
|
|
34
35
|
};
|
|
35
36
|
var calculateScale = function calculateScale(getRatio) {
|
|
37
|
+
if ((0, _expValEquals.expValEquals)('platform_editor_emoji_default_scale', 'isEnabled', true)) {
|
|
38
|
+
// retina display
|
|
39
|
+
if (getRatio() > 1) {
|
|
40
|
+
return {
|
|
41
|
+
scale: 'XXXHDPI',
|
|
42
|
+
altScale: 'XXXHDPI'
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
// default set used for desktop
|
|
46
|
+
return {
|
|
47
|
+
altScale: 'XXXHDPI'
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
|
|
36
51
|
// Retina display
|
|
37
52
|
if (getRatio() > 1) {
|
|
38
53
|
return {
|
|
@@ -128,9 +143,9 @@ var denormaliseEmojiServiceResponse = exports.denormaliseEmojiServiceResponse =
|
|
|
128
143
|
var newSkinVariations = denormaliseSkinEmoji(emoji, emojiData.meta);
|
|
129
144
|
|
|
130
145
|
// create trimmedServiceDesc which is emoji with no representations or skinVariations
|
|
131
|
-
var
|
|
132
|
-
|
|
133
|
-
|
|
146
|
+
var _representation = emoji.representation,
|
|
147
|
+
_skinVariations = emoji.skinVariations,
|
|
148
|
+
_altRepresentations = emoji.altRepresentations,
|
|
134
149
|
trimmedServiceDesc = (0, _objectWithoutProperties2.default)(emoji, _excluded4);
|
|
135
150
|
var response = _objectSpread(_objectSpread({}, trimmedServiceDesc), {}, {
|
|
136
151
|
representation: newRepresentation,
|
|
@@ -20,7 +20,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
|
|
|
20
20
|
actionSubjectId: actionSubjectId,
|
|
21
21
|
attributes: _objectSpread({
|
|
22
22
|
packageName: "@atlaskit/emoji",
|
|
23
|
-
packageVersion: "
|
|
23
|
+
packageVersion: "0.0.0-development"
|
|
24
24
|
}, attributes)
|
|
25
25
|
};
|
|
26
26
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { utils as serviceUtils } from '@atlaskit/util-service-support';
|
|
2
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
2
3
|
import { isImageRepresentation, isSpriteServiceRepresentation, convertImageToMediaRepresentation, buildEmojiDescriptionWithAltRepresentation } from '../util/type-helpers';
|
|
3
4
|
import debug from '../util/logger';
|
|
4
5
|
export const emojiRequest = (provider, options) => {
|
|
@@ -22,6 +23,20 @@ export const emojiRequest = (provider, options) => {
|
|
|
22
23
|
return serviceUtils.requestService(serviceConfig, requestOptions);
|
|
23
24
|
};
|
|
24
25
|
const calculateScale = getRatio => {
|
|
26
|
+
if (expValEquals('platform_editor_emoji_default_scale', 'isEnabled', true)) {
|
|
27
|
+
// retina display
|
|
28
|
+
if (getRatio() > 1) {
|
|
29
|
+
return {
|
|
30
|
+
scale: 'XXXHDPI',
|
|
31
|
+
altScale: 'XXXHDPI'
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
// default set used for desktop
|
|
35
|
+
return {
|
|
36
|
+
altScale: 'XXXHDPI'
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
|
|
25
40
|
// Retina display
|
|
26
41
|
if (getRatio() > 1) {
|
|
27
42
|
return {
|
|
@@ -122,9 +137,9 @@ export const denormaliseEmojiServiceResponse = emojiData => {
|
|
|
122
137
|
|
|
123
138
|
// create trimmedServiceDesc which is emoji with no representations or skinVariations
|
|
124
139
|
const {
|
|
125
|
-
representation,
|
|
126
|
-
skinVariations,
|
|
127
|
-
altRepresentations,
|
|
140
|
+
representation: _representation,
|
|
141
|
+
skinVariations: _skinVariations,
|
|
142
|
+
altRepresentations: _altRepresentations,
|
|
128
143
|
...trimmedServiceDesc
|
|
129
144
|
} = emoji;
|
|
130
145
|
const response = {
|
|
@@ -7,6 +7,7 @@ var _excluded = ["getRatio"],
|
|
|
7
7
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
8
8
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
9
9
|
import { utils as serviceUtils } from '@atlaskit/util-service-support';
|
|
10
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
10
11
|
import { isImageRepresentation, isSpriteServiceRepresentation, convertImageToMediaRepresentation, buildEmojiDescriptionWithAltRepresentation } from '../util/type-helpers';
|
|
11
12
|
import debug from '../util/logger';
|
|
12
13
|
export var emojiRequest = function emojiRequest(provider, options) {
|
|
@@ -26,6 +27,20 @@ export var emojiRequest = function emojiRequest(provider, options) {
|
|
|
26
27
|
return serviceUtils.requestService(serviceConfig, requestOptions);
|
|
27
28
|
};
|
|
28
29
|
var calculateScale = function calculateScale(getRatio) {
|
|
30
|
+
if (expValEquals('platform_editor_emoji_default_scale', 'isEnabled', true)) {
|
|
31
|
+
// retina display
|
|
32
|
+
if (getRatio() > 1) {
|
|
33
|
+
return {
|
|
34
|
+
scale: 'XXXHDPI',
|
|
35
|
+
altScale: 'XXXHDPI'
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
// default set used for desktop
|
|
39
|
+
return {
|
|
40
|
+
altScale: 'XXXHDPI'
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
|
|
29
44
|
// Retina display
|
|
30
45
|
if (getRatio() > 1) {
|
|
31
46
|
return {
|
|
@@ -121,9 +136,9 @@ export var denormaliseEmojiServiceResponse = function denormaliseEmojiServiceRes
|
|
|
121
136
|
var newSkinVariations = denormaliseSkinEmoji(emoji, emojiData.meta);
|
|
122
137
|
|
|
123
138
|
// create trimmedServiceDesc which is emoji with no representations or skinVariations
|
|
124
|
-
var
|
|
125
|
-
|
|
126
|
-
|
|
139
|
+
var _representation = emoji.representation,
|
|
140
|
+
_skinVariations = emoji.skinVariations,
|
|
141
|
+
_altRepresentations = emoji.altRepresentations,
|
|
127
142
|
trimmedServiceDesc = _objectWithoutProperties(emoji, _excluded4);
|
|
128
143
|
var response = _objectSpread(_objectSpread({}, trimmedServiceDesc), {}, {
|
|
129
144
|
representation: newRepresentation,
|
|
@@ -13,7 +13,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
|
|
|
13
13
|
actionSubjectId: actionSubjectId,
|
|
14
14
|
attributes: _objectSpread({
|
|
15
15
|
packageName: "@atlaskit/emoji",
|
|
16
|
-
packageVersion: "
|
|
16
|
+
packageVersion: "0.0.0-development"
|
|
17
17
|
}, attributes)
|
|
18
18
|
};
|
|
19
19
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/emoji",
|
|
3
|
-
"version": "69.10.
|
|
3
|
+
"version": "69.10.20",
|
|
4
4
|
"description": "Fabric emoji React components",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"@atlaskit/spinner": "^19.0.0",
|
|
48
48
|
"@atlaskit/textfield": "^8.2.0",
|
|
49
49
|
"@atlaskit/theme": "^21.0.0",
|
|
50
|
-
"@atlaskit/tmp-editor-statsig": "^29.
|
|
50
|
+
"@atlaskit/tmp-editor-statsig": "^29.3.0",
|
|
51
51
|
"@atlaskit/tokens": "^11.0.0",
|
|
52
52
|
"@atlaskit/tooltip": "^20.14.0",
|
|
53
53
|
"@atlaskit/ufo": "^0.4.0",
|