@atlaskit/reactions 22.10.7 → 22.10.8
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/analytics/index.js +1 -1
- package/dist/cjs/store/MemoryReactionsStore.js +7 -1
- package/dist/es2019/analytics/index.js +1 -1
- package/dist/es2019/store/MemoryReactionsStore.js +7 -1
- package/dist/esm/analytics/index.js +1 -1
- package/dist/esm/store/MemoryReactionsStore.js +7 -1
- package/dist/types/store/MemoryReactionsStore.d.ts +1 -0
- package/dist/types-ts4.5/store/MemoryReactionsStore.d.ts +1 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/reactions
|
|
2
2
|
|
|
3
|
+
## 22.10.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#128413](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/128413)
|
|
8
|
+
[`cc1157d1b37f9`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/cc1157d1b37f9) -
|
|
9
|
+
[ux] Ensure that particle animations only appear once after adding reaction
|
|
10
|
+
|
|
3
11
|
## 22.10.7
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -11,7 +11,7 @@ var _analyticsGasTypes = require("@atlaskit/analytics-gas-types");
|
|
|
11
11
|
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; }
|
|
12
12
|
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) { (0, _defineProperty2.default)(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; }
|
|
13
13
|
var packageName = "@atlaskit/reactions";
|
|
14
|
-
var packageVersion = "22.10.
|
|
14
|
+
var packageVersion = "22.10.8";
|
|
15
15
|
/**
|
|
16
16
|
* TODO: move to utility package?
|
|
17
17
|
* A random sampling function
|
|
@@ -93,6 +93,12 @@ var MemoryReactionsStore = exports.MemoryReactionsStore = /*#__PURE__*/function
|
|
|
93
93
|
return _this.setFlash(reaction.containerAri, reaction.ari, reaction.emojiId, false);
|
|
94
94
|
}, 700);
|
|
95
95
|
});
|
|
96
|
+
(0, _defineProperty2.default)(this, "displayParticleEffect", function (reaction) {
|
|
97
|
+
_this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, true);
|
|
98
|
+
window.setTimeout(function () {
|
|
99
|
+
_this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, false);
|
|
100
|
+
}, 1500);
|
|
101
|
+
});
|
|
96
102
|
(0, _defineProperty2.default)(this, "optmisticUpdate", function (containerAri, ari, emojiId) {
|
|
97
103
|
return function (updater) {
|
|
98
104
|
_this.withReadyReaction(containerAri, ari)(function (reactionState) {
|
|
@@ -133,7 +139,7 @@ var MemoryReactionsStore = exports.MemoryReactionsStore = /*#__PURE__*/function
|
|
|
133
139
|
emojiId = reaction.emojiId;
|
|
134
140
|
_this.optmisticUpdate(containerAri, ari, emojiId)(_utils.addOne);
|
|
135
141
|
_this.flash(reaction);
|
|
136
|
-
_this.
|
|
142
|
+
_this.displayParticleEffect(reaction);
|
|
137
143
|
var exp = ufoExperiences.add.getInstance("".concat(ari, "|").concat(emojiId));
|
|
138
144
|
// ufo start reaction experience
|
|
139
145
|
exp.start();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createAndFireEvent } from '@atlaskit/analytics-next';
|
|
2
2
|
import { UI_EVENT_TYPE, OPERATIONAL_EVENT_TYPE } from '@atlaskit/analytics-gas-types';
|
|
3
3
|
const packageName = "@atlaskit/reactions";
|
|
4
|
-
const packageVersion = "22.10.
|
|
4
|
+
const packageVersion = "22.10.8";
|
|
5
5
|
/**
|
|
6
6
|
* TODO: move to utility package?
|
|
7
7
|
* A random sampling function
|
|
@@ -81,6 +81,12 @@ export class MemoryReactionsStore {
|
|
|
81
81
|
this.setFlash(reaction.containerAri, reaction.ari, reaction.emojiId, true);
|
|
82
82
|
window.setTimeout(() => this.setFlash(reaction.containerAri, reaction.ari, reaction.emojiId, false), 700);
|
|
83
83
|
});
|
|
84
|
+
_defineProperty(this, "displayParticleEffect", reaction => {
|
|
85
|
+
this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, true);
|
|
86
|
+
window.setTimeout(() => {
|
|
87
|
+
this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, false);
|
|
88
|
+
}, 1500);
|
|
89
|
+
});
|
|
84
90
|
_defineProperty(this, "optmisticUpdate", (containerAri, ari, emojiId) => updater => {
|
|
85
91
|
this.withReadyReaction(containerAri, ari)(reactionState => {
|
|
86
92
|
let found = false;
|
|
@@ -123,7 +129,7 @@ export class MemoryReactionsStore {
|
|
|
123
129
|
} = reaction;
|
|
124
130
|
this.optmisticUpdate(containerAri, ari, emojiId)(addOne);
|
|
125
131
|
this.flash(reaction);
|
|
126
|
-
this.
|
|
132
|
+
this.displayParticleEffect(reaction);
|
|
127
133
|
const exp = ufoExperiences.add.getInstance(`${ari}|${emojiId}`);
|
|
128
134
|
// ufo start reaction experience
|
|
129
135
|
exp.start();
|
|
@@ -4,7 +4,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
4
4
|
import { createAndFireEvent } from '@atlaskit/analytics-next';
|
|
5
5
|
import { UI_EVENT_TYPE, OPERATIONAL_EVENT_TYPE } from '@atlaskit/analytics-gas-types';
|
|
6
6
|
var packageName = "@atlaskit/reactions";
|
|
7
|
-
var packageVersion = "22.10.
|
|
7
|
+
var packageVersion = "22.10.8";
|
|
8
8
|
/**
|
|
9
9
|
* TODO: move to utility package?
|
|
10
10
|
* A random sampling function
|
|
@@ -88,6 +88,12 @@ export var MemoryReactionsStore = /*#__PURE__*/function () {
|
|
|
88
88
|
return _this.setFlash(reaction.containerAri, reaction.ari, reaction.emojiId, false);
|
|
89
89
|
}, 700);
|
|
90
90
|
});
|
|
91
|
+
_defineProperty(this, "displayParticleEffect", function (reaction) {
|
|
92
|
+
_this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, true);
|
|
93
|
+
window.setTimeout(function () {
|
|
94
|
+
_this.setParticleEffectForEmoji(reaction.containerAri, reaction.ari, reaction.emojiId, false);
|
|
95
|
+
}, 1500);
|
|
96
|
+
});
|
|
91
97
|
_defineProperty(this, "optmisticUpdate", function (containerAri, ari, emojiId) {
|
|
92
98
|
return function (updater) {
|
|
93
99
|
_this.withReadyReaction(containerAri, ari)(function (reactionState) {
|
|
@@ -128,7 +134,7 @@ export var MemoryReactionsStore = /*#__PURE__*/function () {
|
|
|
128
134
|
emojiId = reaction.emojiId;
|
|
129
135
|
_this.optmisticUpdate(containerAri, ari, emojiId)(addOne);
|
|
130
136
|
_this.flash(reaction);
|
|
131
|
-
_this.
|
|
137
|
+
_this.displayParticleEffect(reaction);
|
|
132
138
|
var exp = ufoExperiences.add.getInstance("".concat(ari, "|").concat(emojiId));
|
|
133
139
|
// ufo start reaction experience
|
|
134
140
|
exp.start();
|
|
@@ -54,6 +54,7 @@ export declare class MemoryReactionsStore implements Store {
|
|
|
54
54
|
private setFlash;
|
|
55
55
|
private flash;
|
|
56
56
|
private setParticleEffectForEmoji;
|
|
57
|
+
private displayParticleEffect;
|
|
57
58
|
private optmisticUpdate;
|
|
58
59
|
/**
|
|
59
60
|
* Utility function to help execute a callback to Reaction if its state is ready.
|
|
@@ -54,6 +54,7 @@ export declare class MemoryReactionsStore implements Store {
|
|
|
54
54
|
private setFlash;
|
|
55
55
|
private flash;
|
|
56
56
|
private setParticleEffectForEmoji;
|
|
57
|
+
private displayParticleEffect;
|
|
57
58
|
private optmisticUpdate;
|
|
58
59
|
/**
|
|
59
60
|
* Utility function to help execute a callback to Reaction if its state is ready.
|