Merge pull request #5531 from LLK/release/2021-06-02

[Master] Release 2021-06-02
This commit is contained in:
chrisgarrity 2021-06-03 11:28:37 -04:00 committed by GitHub
commit 5cffadd929
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 437 additions and 179 deletions

227
package-lock.json generated
View file

@ -219,9 +219,9 @@
}
},
"@babel/compat-data": {
"version": "7.14.0",
"resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.14.0.tgz",
"integrity": "sha512-vu9V3uMM/1o5Hl5OekMUowo3FqXLJSw+s+66nt0fSWVWTtmosdzn45JHOB3cPtZoe6CTBDzvSw0RdOY85Q37+Q==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.14.4.tgz",
"integrity": "sha512-i2wXrWQNkH6JplJQGn3Rd2I4Pij8GdHkXwHMxm+zV5YG/Jci+bCNrWZEWC4o+umiDkRrRs4dVzH3X4GP7vyjQQ==",
"dev": true
},
"@babel/core": {
@ -308,9 +308,9 @@
}
},
"@babel/parser": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.3.tgz",
"integrity": "sha512-7MpZDIfI7sUC5zWo2+foJ50CSI5lcqDehZ0lVgIhSi4bFEk94fLAKlF3Q0nzSQQ+ca0lm+O6G9ztKVBeu8PMRQ==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz",
"integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==",
"dev": true
},
"@babel/template": {
@ -341,9 +341,9 @@
}
},
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -478,14 +478,14 @@
}
},
"@babel/helper-compilation-targets": {
"version": "7.13.16",
"resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.16.tgz",
"integrity": "sha512-3gmkYIrpqsLlieFwjkGgLaSHmhnvlAYzZLlYVjlW+QwI+1zE17kGxuJGmIqDQdYp56XdmGeD+Bswx0UTyG18xA==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.14.4.tgz",
"integrity": "sha512-JgdzOYZ/qGaKTVkn5qEDV/SXAh8KcyUVkCoSWGN8T3bwrgd6m+/dJa2kVGi6RJYJgEYPBdZ84BZp9dUjNWkBaA==",
"dev": true,
"requires": {
"@babel/compat-data": "^7.13.15",
"@babel/compat-data": "^7.14.4",
"@babel/helper-validator-option": "^7.12.17",
"browserslist": "^4.14.5",
"browserslist": "^4.16.6",
"semver": "^6.3.0"
},
"dependencies": {
@ -503,9 +503,9 @@
}
},
"electron-to-chromium": {
"version": "1.3.739",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.739.tgz",
"integrity": "sha512-+LPJVRsN7hGZ9EIUUiWCpO7l4E3qBYHNadazlucBfsXBbccDFNKUBAgzE68FnkWGJPwD/AfKhSzL+G+Iqb8A4A==",
"version": "1.3.743",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.743.tgz",
"integrity": "sha512-K2wXfo9iZQzNJNx67+Pld0DRF+9bYinj62gXCdgPhcu1vidwVuLPHQPPFnCdO55njWigXXpfBiT90jGUPbw8Zg==",
"dev": true
},
"semver": {
@ -546,9 +546,9 @@
},
"dependencies": {
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -573,9 +573,9 @@
},
"dependencies": {
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -667,9 +667,9 @@
}
},
"@babel/parser": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.3.tgz",
"integrity": "sha512-7MpZDIfI7sUC5zWo2+foJ50CSI5lcqDehZ0lVgIhSi4bFEk94fLAKlF3Q0nzSQQ+ca0lm+O6G9ztKVBeu8PMRQ==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz",
"integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==",
"dev": true
},
"@babel/template": {
@ -700,9 +700,9 @@
}
},
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -789,9 +789,9 @@
},
"dependencies": {
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -813,15 +813,15 @@
"dev": true
},
"@babel/helper-replace-supers": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.14.3.tgz",
"integrity": "sha512-Rlh8qEWZSTfdz+tgNV/N4gz1a0TMNwCUcENhMjHTHKp3LseYH5Jha0NSlyTQWMnjbYcwFt+bqAMqSLHVXkQ6UA==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.14.4.tgz",
"integrity": "sha512-zZ7uHCWlxfEAAOVDYQpEf/uyi1dmeC7fX4nCf2iz9drnCwi1zvwXL3HwWWNXUQEJ1k23yVn3VbddiI9iJEXaTQ==",
"dev": true,
"requires": {
"@babel/helper-member-expression-to-functions": "^7.13.12",
"@babel/helper-optimise-call-expression": "^7.12.13",
"@babel/traverse": "^7.14.2",
"@babel/types": "^7.14.2"
"@babel/types": "^7.14.4"
},
"dependencies": {
"@babel/code-frame": {
@ -885,9 +885,9 @@
}
},
"@babel/parser": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.3.tgz",
"integrity": "sha512-7MpZDIfI7sUC5zWo2+foJ50CSI5lcqDehZ0lVgIhSi4bFEk94fLAKlF3Q0nzSQQ+ca0lm+O6G9ztKVBeu8PMRQ==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz",
"integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==",
"dev": true
},
"@babel/template": {
@ -918,9 +918,9 @@
}
},
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -1007,9 +1007,9 @@
},
"dependencies": {
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -1117,9 +1117,9 @@
}
},
"@babel/parser": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.3.tgz",
"integrity": "sha512-7MpZDIfI7sUC5zWo2+foJ50CSI5lcqDehZ0lVgIhSi4bFEk94fLAKlF3Q0nzSQQ+ca0lm+O6G9ztKVBeu8PMRQ==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz",
"integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==",
"dev": true
},
"@babel/template": {
@ -1150,9 +1150,9 @@
}
},
"@babel/types": {
"version": "7.14.2",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.2.tgz",
"integrity": "sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==",
"version": "7.14.4",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.14.4.tgz",
"integrity": "sha512-lCj4aIs0xUefJFQnwwQv2Bxg7Omd6bgquZ6LGC+gGMh6/s5qDVfjuCMlDmYQ15SLsWHd9n+X3E75lKIhl5Lkiw==",
"dev": true,
"requires": {
"@babel/helper-validator-identifier": "^7.14.0",
@ -1368,6 +1368,23 @@
}
}
},
"@formatjs/ecma402-abstract": {
"version": "1.9.2",
"resolved": "https://registry.npmjs.org/@formatjs/ecma402-abstract/-/ecma402-abstract-1.9.2.tgz",
"integrity": "sha512-sZ4GHcitIBz837RSatMDr/6GkYT8hUDffvW+bo2N5lRrBmLk37i0IGSmsxZ6QcxLu2GuymN/4gATEyL/50z3Bg==",
"dev": true,
"requires": {
"tslib": "^2.1.0"
},
"dependencies": {
"tslib": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.2.0.tgz",
"integrity": "sha512-gS9GVHRU+RGn5KQM2rllAlR3dU6m7AcpJKdtH8gFvQiC4Otgk98XnmMU+nZenHt/+VhnBPWwgrJsyrdcw6i23w==",
"dev": true
}
}
},
"@formatjs/intl-getcanonicallocales": {
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/@formatjs/intl-getcanonicallocales/-/intl-getcanonicallocales-1.7.0.tgz",
@ -1387,26 +1404,17 @@
}
},
"@formatjs/intl-locale": {
"version": "2.4.28",
"resolved": "https://registry.npmjs.org/@formatjs/intl-locale/-/intl-locale-2.4.28.tgz",
"integrity": "sha512-z20qVhgtHFTCGLDCl/pWs3cdnxGT4whsbjxwfrhyF2Qf0TNYWrJ/y88f3vINJ19iGVY3GJ6bxaRI5d+uyQ/7ig==",
"version": "2.4.29",
"resolved": "https://registry.npmjs.org/@formatjs/intl-locale/-/intl-locale-2.4.29.tgz",
"integrity": "sha512-pzcnJi7CP/29aFLm8cch00r0kRWIYliyxRCUIOwdwVmCtQxbMBlxExzP/xPmyJgoAuONy42Ol1Y9Cabgy6r8XA==",
"dev": true,
"requires": {
"@formatjs/ecma402-abstract": "1.9.1",
"@formatjs/ecma402-abstract": "1.9.2",
"@formatjs/intl-getcanonicallocales": "1.7.0",
"cldr-core": "38",
"tslib": "^2.1.0"
},
"dependencies": {
"@formatjs/ecma402-abstract": {
"version": "1.9.1",
"resolved": "https://registry.npmjs.org/@formatjs/ecma402-abstract/-/ecma402-abstract-1.9.1.tgz",
"integrity": "sha512-XAJ1ygWKgGEaFuNg3Cf+maJNYEJjl5LjSVZ1iAnSaOKDg/VXa+dDPWhWQP6jimvWv6h9NyDj6Zgh+2qFBeVABw==",
"dev": true,
"requires": {
"tslib": "^2.1.0"
}
},
"tslib": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.2.0.tgz",
@ -1416,24 +1424,15 @@
}
},
"@formatjs/intl-pluralrules": {
"version": "4.0.22",
"resolved": "https://registry.npmjs.org/@formatjs/intl-pluralrules/-/intl-pluralrules-4.0.22.tgz",
"integrity": "sha512-4pSxb31AsjZXUjQHid9eJuUJrXqLOH3tgfiryvBfgNoS76cqk0cFUAuTGdC07YQZlVuJ4c3K4rqBlRpFJwn4Mg==",
"version": "4.0.24",
"resolved": "https://registry.npmjs.org/@formatjs/intl-pluralrules/-/intl-pluralrules-4.0.24.tgz",
"integrity": "sha512-IcCzjuKMBCd3fCcvoQJBsVrfFFcyNgyihS0wdZip9Cv8r41eOGS6oT0haQvbWoAI9ANRh/q3MtqG3Qh9QT1RGw==",
"dev": true,
"requires": {
"@formatjs/ecma402-abstract": "1.9.1",
"@formatjs/ecma402-abstract": "1.9.2",
"tslib": "^2.1.0"
},
"dependencies": {
"@formatjs/ecma402-abstract": {
"version": "1.9.1",
"resolved": "https://registry.npmjs.org/@formatjs/ecma402-abstract/-/ecma402-abstract-1.9.1.tgz",
"integrity": "sha512-XAJ1ygWKgGEaFuNg3Cf+maJNYEJjl5LjSVZ1iAnSaOKDg/VXa+dDPWhWQP6jimvWv6h9NyDj6Zgh+2qFBeVABw==",
"dev": true,
"requires": {
"tslib": "^2.1.0"
}
},
"tslib": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.2.0.tgz",
@ -20856,9 +20855,9 @@
}
},
"scratch-blocks": {
"version": "0.1.0-prerelease.20210526033756",
"resolved": "https://registry.npmjs.org/scratch-blocks/-/scratch-blocks-0.1.0-prerelease.20210526033756.tgz",
"integrity": "sha512-KI5qN+EUhrqRfyCgW7/on3pZuzGxxpWhnTdsv7t4PS4fpOmjTMWXxFg2bCh0pJcFrOWHCF/SfQZh/fhwtmaDGg==",
"version": "0.1.0-prerelease.20210602032919",
"resolved": "https://registry.npmjs.org/scratch-blocks/-/scratch-blocks-0.1.0-prerelease.20210602032919.tgz",
"integrity": "sha512-400Ap0AFCIaGiT7dNPVJ0nPCSTtBqId+bJuoo6tPh9WFzMOF2FsbiX1sFtkNnn1QxCfsgRN0EK5iGb0YfuSmLg==",
"dev": true,
"requires": {
"exports-loader": "0.6.3",
@ -20866,9 +20865,9 @@
}
},
"scratch-gui": {
"version": "0.1.0-prerelease.20210526041028",
"resolved": "https://registry.npmjs.org/scratch-gui/-/scratch-gui-0.1.0-prerelease.20210526041028.tgz",
"integrity": "sha512-BUgeYEXcs3rbPQb+V93mQX5sXvE2z1Biq2+bSQuWWZzahJKCuLgfwSlBio5T2NTFk0G0QekQmmX5hasvDTPEtw==",
"version": "0.1.0-prerelease.20210602035258",
"resolved": "https://registry.npmjs.org/scratch-gui/-/scratch-gui-0.1.0-prerelease.20210602035258.tgz",
"integrity": "sha512-zJYMc7ACT4oQWVVQZoS5Zgsvqct8vu9p0hIiU67ySF0/WhCF38tsk66SoTYDl0Oa4xzs7kIoKIqt8Hh/+rviXg==",
"dev": true,
"requires": {
"arraybuffer-loader": "^1.0.6",
@ -20919,14 +20918,14 @@
"redux": "3.7.2",
"redux-throttle": "0.1.1",
"scratch-audio": "0.1.0-prerelease.20200528195344",
"scratch-blocks": "0.1.0-prerelease.20210526033756",
"scratch-l10n": "3.11.20210526031609",
"scratch-blocks": "0.1.0-prerelease.20210602032919",
"scratch-l10n": "3.11.20210602031702",
"scratch-paint": "0.2.0-prerelease.20210407203313",
"scratch-render": "0.1.0-prerelease.20210325231800",
"scratch-render-fonts": "1.0.0-prerelease.20210401210003",
"scratch-storage": "1.3.4",
"scratch-storage": "1.3.5",
"scratch-svg-renderer": "0.2.0-prerelease.20210511195415",
"scratch-vm": "0.2.0-prerelease.20210510162256",
"scratch-vm": "0.2.0-prerelease.20210601191643",
"startaudiocontext": "1.2.1",
"style-loader": "^0.23.0",
"text-encoding": "0.7.0",
@ -21089,9 +21088,9 @@
"dev": true
},
"electron-to-chromium": {
"version": "1.3.739",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.739.tgz",
"integrity": "sha512-+LPJVRsN7hGZ9EIUUiWCpO7l4E3qBYHNadazlucBfsXBbccDFNKUBAgzE68FnkWGJPwD/AfKhSzL+G+Iqb8A4A==",
"version": "1.3.743",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.743.tgz",
"integrity": "sha512-K2wXfo9iZQzNJNx67+Pld0DRF+9bYinj62gXCdgPhcu1vidwVuLPHQPPFnCdO55njWigXXpfBiT90jGUPbw8Zg==",
"dev": true
},
"has-flag": {
@ -21312,28 +21311,17 @@
"dev": true
},
"scratch-storage": {
"version": "1.3.4",
"resolved": "https://registry.npmjs.org/scratch-storage/-/scratch-storage-1.3.4.tgz",
"integrity": "sha512-BuMwX0337JKdHI90k9ULu5AapxMiVhwUTD9GEtAIUjyLUdiWO9MHCC0pzfrEXwosMV3BxtFzTe21UiSkWK9Pcw==",
"version": "1.3.5",
"resolved": "https://registry.npmjs.org/scratch-storage/-/scratch-storage-1.3.5.tgz",
"integrity": "sha512-MrIRidvUJtncx0xlMJDng9KypHR3/kyCE2stXJ1CYNLTWrl2pGCpNNcYWygRQw7aFQ0hIzP/Z118T8X53sUDAA==",
"dev": true,
"requires": {
"arraybuffer-loader": "^1.0.8",
"arraybuffer-loader": "^1.0.3",
"base64-js": "1.3.0",
"fastestsmallesttextencoderdecoder": "^1.0.7",
"js-md5": "0.7.3",
"minilog": "3.1.0",
"worker-loader": "^2.0.0"
},
"dependencies": {
"arraybuffer-loader": {
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/arraybuffer-loader/-/arraybuffer-loader-1.0.8.tgz",
"integrity": "sha512-CwUVCcxCgcgZUu2w741OV6Xj1tvRVQebq22RCyGXiLgJOJ4e4M/59EPYdtK2MLfIN28t1TDvuh2ojstNq3Kh5g==",
"dev": true,
"requires": {
"loader-utils": "^1.1.0"
}
}
}
},
"source-list-map": {
@ -21388,9 +21376,9 @@
}
},
"scratch-l10n": {
"version": "3.11.20210526031609",
"resolved": "https://registry.npmjs.org/scratch-l10n/-/scratch-l10n-3.11.20210526031609.tgz",
"integrity": "sha512-Lr2d09o92jgBptCA5FfC3U9YXesKhPAVzRTQkydsz7DpQKmMilI81gxP6o5CLzxi85hyzZmvIRGlhRIhfHbgBQ==",
"version": "3.11.20210602031702",
"resolved": "https://registry.npmjs.org/scratch-l10n/-/scratch-l10n-3.11.20210602031702.tgz",
"integrity": "sha512-8WCD4B/GLtAepFvJc29fGwMI0yH7ZuRwDLO2oUy8gbdCw1piJBtJVNv9nrsqIE+GjgQYn87anglf9vDb34m/ig==",
"dev": true,
"requires": {
"@babel/cli": "^7.1.2",
@ -21478,15 +21466,6 @@
"twgl.js": "4.4.0"
},
"dependencies": {
"arraybuffer-loader": {
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/arraybuffer-loader/-/arraybuffer-loader-1.0.8.tgz",
"integrity": "sha512-CwUVCcxCgcgZUu2w741OV6Xj1tvRVQebq22RCyGXiLgJOJ4e4M/59EPYdtK2MLfIN28t1TDvuh2ojstNq3Kh5g==",
"dev": true,
"requires": {
"loader-utils": "^1.1.0"
}
},
"base64-js": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.0.tgz",
@ -21524,12 +21503,12 @@
}
},
"scratch-storage": {
"version": "1.3.4",
"resolved": "https://registry.npmjs.org/scratch-storage/-/scratch-storage-1.3.4.tgz",
"integrity": "sha512-BuMwX0337JKdHI90k9ULu5AapxMiVhwUTD9GEtAIUjyLUdiWO9MHCC0pzfrEXwosMV3BxtFzTe21UiSkWK9Pcw==",
"version": "1.3.5",
"resolved": "https://registry.npmjs.org/scratch-storage/-/scratch-storage-1.3.5.tgz",
"integrity": "sha512-MrIRidvUJtncx0xlMJDng9KypHR3/kyCE2stXJ1CYNLTWrl2pGCpNNcYWygRQw7aFQ0hIzP/Z118T8X53sUDAA==",
"dev": true,
"requires": {
"arraybuffer-loader": "^1.0.8",
"arraybuffer-loader": "^1.0.3",
"base64-js": "1.3.0",
"fastestsmallesttextencoderdecoder": "^1.0.7",
"js-md5": "0.7.3",
@ -21666,9 +21645,9 @@
"dev": true
},
"scratch-vm": {
"version": "0.2.0-prerelease.20210510162256",
"resolved": "https://registry.npmjs.org/scratch-vm/-/scratch-vm-0.2.0-prerelease.20210510162256.tgz",
"integrity": "sha512-14KHdLRoEcpHRsLPkiBNnMDNAtoGYr0ZkAUdHatwvqTfzS1eN22qytqdkJ8Mx3LIxP52K/IMOVq9rFVUZ4df3w==",
"version": "0.2.0-prerelease.20210601191643",
"resolved": "https://registry.npmjs.org/scratch-vm/-/scratch-vm-0.2.0-prerelease.20210601191643.tgz",
"integrity": "sha512-SWXa176Ymo2EER+dEF5yJXGOaq7xekHcmggEJ2p+8vt3LZUlBpmUlL/U1FTY65wjaYLxQWMi7q+d+IpnO/vkEg==",
"dev": true,
"requires": {
"@vernier/godirect": "1.5.0",

View file

@ -126,8 +126,8 @@
"redux-mock-store": "^1.2.3",
"redux-thunk": "2.0.1",
"sass-loader": "6.0.6",
"scratch-gui": "0.1.0-prerelease.20210526041028",
"scratch-l10n": "latest",
"scratch-gui": "0.1.0-prerelease.20210602035258",
"scratch-l10n": "3.11.20210602031702",
"selenium-webdriver": "3.6.0",
"slick-carousel": "1.6.0",
"style-loader": "0.12.3",

View file

@ -338,6 +338,7 @@
"comments.cancel": "Cancel",
"comments.lengthWarning": "{remainingCharacters, plural, one {1 character left} other {{remainingCharacters} characters left}}",
"comments.loadMoreReplies": "See more replies",
"comments.replyLimitReached": "This comment thread has reached its limit. To continue commenting, you can start a new thread.",
"comments.status.delbyusr": "Deleted by project owner",
"comments.status.censbyfilter": "Censored by filter",
"comments.status.delbyparentcomment": "Parent comment deleted",

View file

@ -26,6 +26,7 @@ class Comment extends React.Component {
'handleConfirmReport',
'handleCancelReport',
'handlePostReply',
'handleReply',
'handleToggleReplying',
'handleRestore',
'setRef'
@ -49,6 +50,14 @@ class Comment extends React.Component {
this.props.onAddComment(comment);
}
handleReply () {
if (this.props.hasReachedThreadLimit) {
this.props.onReply(this.props.id, (this.props.parentId || this.props.id));
} else {
this.handleToggleReplying();
}
}
handleToggleReplying () {
this.setState({replying: !this.state.replying});
}
@ -220,7 +229,7 @@ class Comment extends React.Component {
{(canReply && visible) ? (
<span
className="comment-reply"
onClick={this.handleToggleReplying}
onClick={this.handleReply}
>
<FormattedMessage id="comments.reply" />
</span>
@ -278,10 +287,12 @@ Comment.propTypes = {
canRestore: PropTypes.bool,
content: PropTypes.string,
datetimeCreated: PropTypes.string,
hasReachedThreadLimit: PropTypes.bool,
highlighted: PropTypes.bool,
id: PropTypes.number,
onAddComment: PropTypes.func,
onDelete: PropTypes.func,
onReply: PropTypes.func,
onReport: PropTypes.func,
onRestore: PropTypes.func,
parentId: PropTypes.number,

View file

@ -1,5 +1,10 @@
@import "../../../colors";
.compose-row {
margin-top: 30px;
margin-bottom: 40px;
}
.compose-comment {
margin-left: .5rem;
width: 100%;
@ -279,6 +284,15 @@
}
}
.thread-limit-status {
width: calc(100% - 10rem);
margin-left: auto;
.comment-status-icon {
display: none;
}
}
.compose-disabled {
opacity: .5;
}

View file

@ -330,7 +330,7 @@ class ComposeComment extends React.Component {
className={classNames('flex-row',
'comment',
this.state.status === ComposeStatus.REJECTED_MUTE ?
'compose-disabled' : '')}
'compose-disabled' : 'compose-row')}
>
<a href={`/users/${this.props.user.username}`}>
<Avatar src={this.props.user.thumbnailUrl} />

View file

@ -6,9 +6,13 @@ const FormattedMessage = require('react-intl').FormattedMessage;
const FlexRow = require('../../../components/flex-row/flex-row.jsx');
const Comment = require('./comment.jsx');
const CommentingStatus = require('../../../components/commenting-status/commenting-status.jsx');
require('./comment.scss');
// Thread limit only applies if hasThreadLimit prop is true
const THREAD_LIMIT = 25;
class TopLevelComment extends React.Component {
constructor (props) {
super(props);
@ -16,11 +20,14 @@ class TopLevelComment extends React.Component {
'handleExpandThread',
'handleAddComment',
'handleDeleteReply',
'handleReplyStatus',
'handleReportReply',
'handleRestoreReply'
]);
this.state = {
expanded: this.props.defaultExpanded
expanded: this.props.defaultExpanded,
threadLimitCommentId: '',
threadLimitParentId: ''
};
// A cache of {userId: username, ...} in order to show reply usernames
@ -55,6 +62,12 @@ class TopLevelComment extends React.Component {
this.props.onAddComment(comment, this.props.id);
}
handleReplyStatus (id, parentId) {
// Send the parentId up to track which thread got "reply" clicked on
if (this.props.onReply) this.props.onReply(parentId);
this.setState({threadLimitCommentId: id, threadLimitParentId: parentId});
}
authorUsername (authorId) {
if (this.authorUsernameCache[authorId]) return this.authorUsernameCache[authorId];
@ -80,6 +93,7 @@ class TopLevelComment extends React.Component {
canRestore,
content,
datetimeCreated,
hasThreadLimit,
highlightedCommentId,
id,
moreRepliesToLoad,
@ -88,17 +102,39 @@ class TopLevelComment extends React.Component {
onRestore,
replies,
postURI,
threadHasReplyStatus,
visibility
} = this.props;
const parentVisible = visibility === 'visible';
// Check whether this comment thread has reached the thread limit
const hasReachedThreadLimit = hasThreadLimit && replies.length >= THREAD_LIMIT;
/*
Check all the following conditions:
- hasReachedThreadLimit: the thread has reached the limit
- threadHasReplyStatus: this thread should be showing the status
(false, if the user just clicked reply elsewhere and another thread/comment stole the status message)
- Use the comment id and parent id of this particular comment in this thread
to see if it has the reply status,
only one comment in a thread can have the status
All of these conditions together ensure that the user only sees one status message on the comments page.
*/
const commentHasReplyStatus = (commentId, commentParentId) =>
hasReachedThreadLimit &&
threadHasReplyStatus &&
(this.state.threadLimitCommentId === commentId) &&
(this.state.threadLimitParentId === commentParentId);
return (
<FlexRow className="comment-container">
<Comment
highlighted={highlightedCommentId === id}
postURI={postURI}
onAddComment={this.handleAddComment}
onReply={this.handleReplyStatus}
{...{
author,
content,
@ -108,6 +144,7 @@ class TopLevelComment extends React.Component {
canReply,
canReport,
canRestore,
hasReachedThreadLimit,
id,
onDelete,
onReport,
@ -115,6 +152,13 @@ class TopLevelComment extends React.Component {
visibility
}}
/>
{commentHasReplyStatus(id, id) &&
<CommentingStatus className="thread-limit-status">
<p>
<FormattedMessage id="comments.replyLimitReached" />
</p>
</CommentingStatus>
}
{replies.length > 0 &&
<FlexRow
className={classNames(
@ -125,27 +169,40 @@ class TopLevelComment extends React.Component {
key={id}
>
{(this.state.expanded ? replies : replies.slice(0, 3)).map(reply => (
<Comment
author={reply.author}
canDelete={canDelete}
canDeleteWithoutConfirm={canDeleteWithoutConfirm}
canReply={canReply}
canReport={canReport}
canRestore={canRestore && parentVisible}
content={reply.content}
datetimeCreated={reply.datetime_created}
highlighted={highlightedCommentId === reply.id}
id={reply.id}
key={reply.id}
parentId={id}
postURI={postURI}
replyUsername={this.authorUsername(reply.commentee_id)}
visibility={reply.visibility}
onAddComment={this.handleAddComment}
onDelete={this.handleDeleteReply}
onReport={this.handleReportReply}
onRestore={this.handleRestoreReply}
/>
<React.Fragment
key={`reply-and-status-${reply.id}`}
>
<Comment
author={reply.author}
canDelete={canDelete}
canDeleteWithoutConfirm={canDeleteWithoutConfirm}
canReply={canReply}
canReport={canReport}
canRestore={canRestore && parentVisible}
content={reply.content}
datetimeCreated={reply.datetime_created}
hasReachedThreadLimit={hasReachedThreadLimit}
highlighted={highlightedCommentId === reply.id}
id={reply.id}
key={reply.id}
parentId={id}
postURI={postURI}
replyUsername={this.authorUsername(reply.commentee_id)}
visibility={reply.visibility}
onAddComment={this.handleAddComment}
onDelete={this.handleDeleteReply}
onReply={this.handleReplyStatus}
onReport={this.handleReportReply}
onRestore={this.handleRestoreReply}
/>
{commentHasReplyStatus(reply.id, id) &&
<CommentingStatus className="thread-limit-status">
<p>
<FormattedMessage id="comments.reachedThreadLimit" />
</p>
</CommentingStatus>
}
</React.Fragment>
))}
{((!this.state.expanded && replies.length > 3) ||
(this.state.expanded && moreRepliesToLoad)) &&
@ -179,24 +236,29 @@ TopLevelComment.propTypes = {
datetimeCreated: PropTypes.string,
defaultExpanded: PropTypes.bool,
deletable: PropTypes.bool,
hasThreadLimit: PropTypes.bool,
highlightedCommentId: PropTypes.oneOfType([PropTypes.number, PropTypes.bool]),
id: PropTypes.number,
moreRepliesToLoad: PropTypes.bool,
onAddComment: PropTypes.func,
onDelete: PropTypes.func,
onLoadMoreReplies: PropTypes.func,
onReply: PropTypes.func,
onReport: PropTypes.func,
onRestore: PropTypes.func,
parentId: PropTypes.number,
postURI: PropTypes.string,
replies: PropTypes.arrayOf(PropTypes.object),
threadHasReplyStatus: PropTypes.bool,
visibility: PropTypes.string
};
TopLevelComment.defaultProps = {
canDeleteWithoutConfirm: false,
defaultExpanded: false,
moreRepliesToLoad: false
hasThreadLimit: false,
moreRepliesToLoad: false,
threadHasReplyStatus: false
};
module.exports = TopLevelComment;

View file

@ -1,3 +1,3 @@
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.0592 15.9577C9.96446 16.0524 9.85758 16.1132 9.72976 16.1709L7.56659 17.0793C7.48799 16.8113 7.29336 16.4707 6.93361 16.1109C6.58592 15.7633 6.25738 15.5807 5.99914 15.4901L6.89672 13.3378C6.94337 13.199 7.0271 13.0934 7.1208 12.9997C7.14262 12.9998 7.16333 12.9791 7.17418 12.9682L7.20476 12.9376C7.35075 12.7917 7.55585 12.7028 7.79617 12.6709C8.40705 12.5953 9.11521 12.8852 9.64935 13.4193C10.1835 13.9535 10.4734 14.6616 10.3857 15.2605C10.3505 15.458 10.2854 15.6613 10.1833 15.8116C10.1529 15.864 10.1114 15.9055 10.069 15.9479L10.0592 15.9577ZM13.6054 6.53701C13.9427 6.19967 14.4603 6.12739 14.9902 6.28635C15.2973 6.37845 15.4255 6.75916 15.2154 6.96926L10.177 12.0077C10.0566 12.128 9.86135 12.1478 9.70333 12.047C9.54003 11.9449 9.37127 11.857 9.20119 11.7836C8.92376 11.664 8.82736 11.315 9.02168 11.1207L13.6054 6.53701ZM16.5317 9.46328L11.9489 14.046C11.7586 14.2364 11.4084 14.1545 11.2923 13.8845C11.2173 13.705 11.1239 13.5307 11.0163 13.362C10.9099 13.1964 10.9364 12.99 11.0616 12.8648L16.0882 7.83815C16.2964 7.63003 16.677 7.75614 16.7711 8.06339C16.9356 8.59871 16.871 9.12397 16.5317 9.46328ZM18.5347 4.534C17.2459 3.24525 15.3869 3.01376 14.3838 4.01691L6.29247 12.1082C6.09421 12.3065 5.91898 12.5278 5.81284 12.7984L4.10642 16.8959C3.89183 17.4132 4.05796 18.0587 4.53397 18.5347C5.00998 19.0107 5.65549 19.1769 6.1728 18.9623L10.2703 17.2558C10.5398 17.1486 10.7611 16.9734 10.9594 16.7751L19.0507 8.68382C20.0538 7.68067 19.8234 5.82274 18.5347 4.534Z" fill="#4C97FF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.0592 15.9579C9.96446 16.0526 9.85758 16.1134 9.72976 16.1711L7.56659 17.0795C7.48799 16.8115 7.29336 16.4709 6.93361 16.1111C6.58592 15.7635 6.25738 15.5809 5.99914 15.4903L6.89672 13.338C6.94337 13.1992 7.0271 13.0936 7.1208 12.9999C7.14262 13 7.16333 12.9793 7.17418 12.9684L7.20476 12.9378C7.35075 12.7919 7.55585 12.703 7.79617 12.6711C8.40705 12.5955 9.11521 12.8854 9.64935 13.4195C10.1835 13.9537 10.4734 14.6618 10.3857 15.2606C10.3505 15.4582 10.2854 15.6615 10.1833 15.8118C10.1529 15.8642 10.1114 15.9057 10.069 15.9481L10.0592 15.9579ZM13.6054 6.53721C13.9427 6.19986 14.4603 6.12759 14.9902 6.28654C15.2973 6.37865 15.4255 6.75936 15.2154 6.96946L10.177 12.0079C10.0566 12.1282 9.86135 12.148 9.70333 12.0472C9.54003 11.9451 9.37127 11.8572 9.20119 11.7838C8.92376 11.6642 8.82736 11.3152 9.02168 11.1209L13.6054 6.53721ZM16.5317 9.46348L11.9489 14.0462C11.7586 14.2366 11.4084 14.1547 11.2923 13.8847C11.2173 13.7052 11.1239 13.5309 11.0163 13.3622C10.9099 13.1966 10.9364 12.9902 11.0616 12.865L16.0882 7.83835C16.2964 7.63022 16.677 7.75634 16.7711 8.06359C16.9356 8.59891 16.871 9.12417 16.5317 9.46348ZM18.5347 4.5342C17.2459 3.24545 15.3869 3.01396 14.3838 4.01711L6.29247 12.1084C6.09421 12.3067 5.91898 12.528 5.81284 12.7986L4.10642 16.8961C3.89183 17.4134 4.05796 18.0589 4.53397 18.5349C5.00998 19.0109 5.65549 19.177 6.1728 18.9625L10.2703 17.256C10.5398 17.1488 10.7611 16.9736 10.9594 16.7753L19.0507 8.68402C20.0538 7.68087 19.8234 5.82294 18.5347 4.5342Z" fill="#4C97FF"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View file

@ -58,11 +58,19 @@
"studio.curatorErrors.alreadyCurator": "They are already part of the studio.",
"studio.curatorErrors.unknownUsername": "Could not invite a curator with that username.",
"studio.curatorErrors.tooFast": "You are adding curators too fast.",
"studio.curatorDoYouWantToPromote": "Do you want to promote this person to a manager?",
"studio.curatorManagersCan": "Managers can...",
"studio.curatorAddAndDeleteCurators": "add and delete curators",
"studio.curatorDeleteManagers": "delete other managers",
"studio.curatorAddAndDeleteProjects": "add and delete projects",
"studio.curatorIfYouTrust": "If you trust this person and youre sure you want to give them extra permissions, click Promote.",
"studio.remove": "Remove",
"studio.promote": "Promote",
"studio.cancel": "Cancel",
"studio.commentsHeader": "Comments",
"studio.commentsNotAllowed": "Commenting for this studio has been turned off.",
"studio.comments.toggleOff": "Commenting off",
"studio.comments.toggleOn": "Commenting on",
"studio.comments.turnedOff": "Sorry, comment posting has been turned off for this studio.",

View file

@ -0,0 +1,73 @@
import React from 'react';
import PropTypes from 'prop-types';
import {FormattedMessage} from 'react-intl';
import Modal from '../../../components/modal/base/modal.jsx';
import ModalTitle from '../../../components/modal/base/modal-title.jsx';
import ModalInnerContent from '../../../components/modal/base/modal-inner-content.jsx';
import './promote-modal.scss';
const PromoteModal = ({
handleClose,
handlePromote,
username
}) => (
<Modal
isOpen
className="promote-modal"
onRequestClose={handleClose}
>
<ModalTitle
className="promote-title"
/>
<div
className="promote-content"
>
<img
src="/svgs/studio/promote-illustration.svg"
className="promote-image"
/>
<ModalInnerContent
className="promote-inner"
>
<h2>
<FormattedMessage id="studio.curatorDoYouWantToPromote" />
<br />
{username}
</h2>
<span><FormattedMessage id="studio.curatorManagersCan" /></span>
<ul>
<li><FormattedMessage id="studio.curatorAddAndDeleteCurators" /></li>
<li><FormattedMessage id="studio.curatorDeleteManagers" /></li>
<li><FormattedMessage id="studio.curatorAddAndDeleteProjects" /></li>
</ul>
<span><FormattedMessage id="studio.curatorIfYouTrust" /></span>
<div
className="promote-button-row"
>
<button
className="button cancel-button"
onClick={handleClose}
>
<FormattedMessage id="studio.cancel" />
</button>
<button
className="button"
onClick={handlePromote}
>
<FormattedMessage id="studio.promote" />
</button>
</div>
</ModalInnerContent>
</div>
</Modal>
);
PromoteModal.propTypes = {
handleClose: PropTypes.func,
handlePromote: PropTypes.func,
username: PropTypes.string
};
export default PromoteModal;

View file

@ -0,0 +1,50 @@
@import "../../../colors";
.promote-modal {
.promote-title {
background: $ui-blue;
border-top-left-radius: 12px;
border-top-right-radius: 12px;
padding-top: .75rem;
width: 100%;
height: 3rem;
cursor: pointer;
}
h2 {
line-height: 2.5rem;
margin-bottom: 1rem;
}
ul {
line-height: 1rem;
}
.promote-content {
display: flex;
align-items: flex-start;
}
.promote-image {
margin-top: 2rem;
}
.promote-inner {
padding: 2rem;
}
.promote-button-row {
display: flex;
justify-content: flex-end;
}
.button {
margin-left: 0.5rem;
}
.cancel-button {
background-color: $ui-white;
color: $ui-blue;
box-shadow: 0px 0px 0 1px $ui-blue;
}
}

View file

@ -0,0 +1,10 @@
const React = require('react');
const FormattedMessage = require('react-intl').FormattedMessage;
const StudioCommentsNotAllowed = () => (
<div className="studio-comments-not-allowed">
<FormattedMessage id="studio.commentsNotAllowed" />
</div>
);
module.exports = StudioCommentsNotAllowed;

View file

@ -1,4 +1,4 @@
import React, {useEffect, useRef} from 'react';
import React, {useEffect, useRef, useState} from 'react';
import PropTypes from 'prop-types';
import {connect} from 'react-redux';
import {FormattedMessage} from 'react-intl';
@ -8,6 +8,7 @@ import ComposeComment from '../preview/comment/compose-comment.jsx';
import TopLevelComment from '../preview/comment/top-level-comment.jsx';
import studioCommentActions from '../../redux/studio-comment-actions.js';
import StudioCommentsAllowed from './studio-comments-allowed.jsx';
import StudioCommentsNotAllowed from './studio-comments-not-allowed.jsx';
import {selectIsAdmin, selectHasFetchedSession} from '../../redux/session';
import {
@ -55,21 +56,37 @@ const StudioComments = ({
if (isAdmin !== wasAdmin) handleResetComments();
}, [isAdmin]);
const [replyStatusCommentId, setReplyStatusCommentId] = useState('');
const hasReplyStatus = function (comment) {
return (
comment.parent_id && comment.parent_id === replyStatusCommentId
) || (comment.id === replyStatusCommentId);
};
const handleReplyStatusChange = function (id) {
setReplyStatusCommentId(id);
};
return (
<div>
<div className="studio-compose-container">
<div className="studio-header-container">
<h2><FormattedMessage id="studio.commentsHeader" /></h2>
{canEditCommentsAllowed && <StudioCommentsAllowed />}
</div>
<div className="studio-compose-container">
{shouldShowCommentComposer && commentsAllowed &&
<ComposeComment
postURI={postURI}
onAddComment={handleNewComment}
/>
<div>
{shouldShowCommentComposer ?
(commentsAllowed ?
<ComposeComment
postURI={postURI}
onAddComment={handleNewComment}
/> :
<StudioCommentsNotAllowed />
) : null
}
{comments.map(comment => (
<TopLevelComment
hasThreadLimit
author={comment.author}
canDelete={canDeleteComment}
canDeleteWithoutConfirm={canDeleteCommentWithoutConfirm}
@ -84,10 +101,13 @@ const StudioComments = ({
parentId={comment.parent_id}
postURI={postURI}
replies={replies && replies[comment.id] ? replies[comment.id] : []}
threadHasReplyStatus={hasReplyStatus(comment)}
visibility={comment.visibility}
onAddComment={handleNewComment}
onDelete={handleDeleteComment}
onRestore={handleRestoreComment}
// eslint-disable-next-line react/jsx-no-bind
onReply={handleReplyStatusChange}
onReport={handleReportComment}
onLoadMoreReplies={handleLoadMoreReplies}
/>

View file

@ -5,6 +5,8 @@ import {connect} from 'react-redux';
import classNames from 'classnames';
import {FormattedMessage} from 'react-intl';
import PromoteModal from './modals/promote-modal.jsx';
import {
selectCanRemoveCurator, selectCanRemoveManager, selectCanPromoteCurators
} from '../../redux/studio-permissions';
@ -24,6 +26,7 @@ const StudioMemberTile = ({
username, image // own props
}) => {
const [submitting, setSubmitting] = useState(false);
const [modalOpen, setModalOpen] = useState(false);
const {errorAlert, successAlert} = useAlertContext();
const userUrl = `/users/${username}`;
return (
@ -45,26 +48,8 @@ const StudioMemberTile = ({
<OverflowMenu>
{canPromote && <li>
<button
className={classNames({
'mod-mutating': submitting
})}
disabled={submitting}
onClick={() => {
setSubmitting(true);
onPromote(username)
.then(() => {
successAlert({
id: 'studio.alertManagerPromote',
values: {name: username}
});
})
.catch(() => {
errorAlert({
id: 'studio.alertManagerPromoteError',
values: {name: username}
});
setSubmitting(false);
});
setModalOpen(true);
}}
>
<img src={promoteIcon} />
@ -94,6 +79,27 @@ const StudioMemberTile = ({
</li>}
</OverflowMenu>
}
{modalOpen &&
<PromoteModal
handleClose={() => setModalOpen(false)}
handlePromote={() => {
onPromote(username)
.then(() => {
successAlert({
id: 'studio.alertManagerPromote',
values: {name: username}
});
})
.catch(() => {
errorAlert({
id: 'studio.alertManagerPromoteError',
values: {name: username}
});
});
}}
username={username}
/>
}
</div>
);
};

View file

@ -425,6 +425,18 @@ $radius: 8px;
padding-top: 8px;
}
.studio-comments-not-allowed {
display: flex;
width: 100%;
background: rgba(76, 151, 255, 0.15);
height: 80px;
border: 1px solid rgba(76, 151, 255, 0.15);
border-radius: 8px;
justify-content: center;
align-items: center;
margin-bottom: 28px;
}
.studio-empty {
grid-column: 1 / -1; /* take up all columns */
text-align: center;

View file

@ -0,0 +1,12 @@
<svg width="190" height="188" viewBox="0 0 190 188" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="mask0" mask-type="alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="190" height="188">
<rect width="190" height="187.853" fill="#C4C4C4"/>
</mask>
<g mask="url(#mask0)">
<path opacity="0.3" fill-rule="evenodd" clip-rule="evenodd" d="M48.2863 7.01099C-26.1432 21.8371 -39.6529 68.6058 -22.1209 121.141C-2.67413 179.413 40.1423 187.854 72.0237 187.854C132.41 187.854 170.703 132.907 167.374 86.0398C162.702 20.2606 116.204 -11.8127 48.2863 7.01099Z" fill="#0FBD8C"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M85.9406 88.4502C84.1234 91.9029 80.5282 93.8792 76.7849 93.4857L65.4775 92.2973C65.4785 92.6363 65.4793 92.9739 65.4801 93.3101C65.5081 104.802 65.5319 114.605 71.0832 123.487C75.1376 129.974 79.2076 134.319 82.2838 137.602C85.5685 141.109 87.7201 143.406 87.5097 145.81C87.1025 150.465 73.354 147.95 60.968 138.266C48.5819 128.582 45.1431 117.469 43.7689 107.967C42.9683 102.431 42.896 95.1075 42.8678 89.9209L30.3232 88.6024C26.5741 88.2084 23.4684 85.5278 22.4146 81.7733C21.3556 78.0122 22.5737 73.9795 25.5155 71.4966L51.292 49.7461C53.2275 48.1124 55.6553 47.3518 58.1162 47.6104C60.5828 47.8697 62.7995 49.1185 64.3473 51.1182L85.0441 77.7533C87.3995 80.793 87.7584 84.9914 85.9406 88.4502Z" fill="white"/>
<path d="M139.916 120.504C135.073 116.185 132.034 109.965 132.034 103.051C132.034 90.0082 142.847 79.4351 156.186 79.4351C169.526 79.4351 180.339 90.0082 180.339 103.051C180.339 109.966 177.299 116.187 172.455 120.506C179.36 125.744 184.599 134.709 187.459 146.951C192.251 167.458 192.147 178.159 155.333 178.159C117.263 178.159 118.657 170.339 121.879 152.275L121.88 152.272C122.046 151.341 122.217 150.384 122.387 149.398C123.072 145.444 124.196 141.72 125.681 138.289C125.594 138.27 125.506 138.252 125.419 138.233C115.666 136.123 103.5 130.492 95.4593 116.666C92.9914 112.422 94.4308 106.981 98.6744 104.513C102.918 102.046 108.359 103.485 110.827 107.729C115.689 116.089 122.84 119.486 129.177 120.857C132.387 121.552 135.307 121.697 137.415 121.664C137.753 121.658 138.068 121.649 138.356 121.636C138.868 121.242 139.389 120.865 139.916 120.504Z" fill="#0EBD8C"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M115.996 44.6556L116.503 52.4363L110.381 57.269C108.294 58.9136 109.001 62.2351 111.575 62.8917L119.136 64.8123L121.837 72.1291C122.757 74.62 126.136 74.9753 127.553 72.7304L131.716 66.1345L139.51 65.8271C142.165 65.7208 143.544 62.6186 141.849 60.5752L136.861 54.5783L138.976 47.0717C139.697 44.5128 137.174 42.2402 134.706 43.2253L127.458 46.1116L120.975 41.7813C118.765 40.3088 115.826 42.0056 115.996 44.6556Z" fill="#0FBD8C"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M163.278 16.3101L160.308 17.2026L157.887 15.2625C157.063 14.6008 155.839 15.1719 155.815 16.2283L155.747 19.3303L153.153 21.0321C152.27 21.6115 152.434 22.9527 153.431 23.3011L156.36 24.3244L157.176 27.3175C157.455 28.337 158.781 28.594 159.421 27.7542L161.299 25.2845L164.398 25.4325C165.454 25.4828 166.109 24.3015 165.506 23.4333L163.739 20.8824L164.837 17.9824C165.21 16.9942 164.29 16.007 163.278 16.3101Z" fill="#0FBD8C"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.1 KiB