We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4c81bad commit 504e025Copy full SHA for 504e025
packages/core/src/utils/ColorPicker.ts
@@ -1818,10 +1818,10 @@ export default function ($, undefined?: any) {
1818
// Returns an 8 character hex
1819
function rgbaToHex(r, g, b, a) {
1820
var hex = [
1821
- pad2(convertDecimalToHex(a)),
1822
pad2(mathRound(r).toString(16)),
1823
pad2(mathRound(g).toString(16)),
1824
pad2(mathRound(b).toString(16)),
+ pad2(convertDecimalToHex(a)),
1825
];
1826
1827
return hex.join('');
@@ -2406,10 +2406,10 @@ export default function ($, undefined?: any) {
2406
}
2407
if ((match = matchers.hex8.exec(color))) {
2408
return {
2409
- a: convertHexToDecimal(match[1]),
2410
- r: parseIntFromHex(match[2]),
2411
- g: parseIntFromHex(match[3]),
2412
- b: parseIntFromHex(match[4]),
+ r: parseIntFromHex(match[1]),
+ g: parseIntFromHex(match[2]),
+ b: parseIntFromHex(match[3]),
+ a: convertHexToDecimal(match[4]),
2413
format: named ? 'name' : 'hex8',
2414
};
2415
0 commit comments