@sinco/react 1.1.1-rc.10 → 1.1.1-rc.11
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/index.js +9 -0
- package/package.json +1 -1
package/index.js
CHANGED
@@ -20116,6 +20116,9 @@ const DynamicColor = async src => {
|
|
20116
20116
|
};
|
20117
20117
|
|
20118
20118
|
const useDynamicColor = url => {
|
20119
|
+
const [primaryAdpro, setPrimaryAdpro] = useState(AdproSincoTheme.palette.primary);
|
20120
|
+
const [secondaryAdpro, setSecondaryAdpro] = useState(AdproSincoTheme.palette.secondary);
|
20121
|
+
const [backgroundAdpro, setBackgroundAdpro] = useState(AdproSincoTheme.palette.background);
|
20119
20122
|
const [primary, setPrimary] = useState(SincoTheme.palette.primary);
|
20120
20123
|
const [secondary, setSecondary] = useState(SincoTheme.palette.secondary);
|
20121
20124
|
const [background, setBackground] = useState(SincoTheme.palette.background);
|
@@ -20129,12 +20132,18 @@ const useDynamicColor = url => {
|
|
20129
20132
|
setPrimary(primaryColor);
|
20130
20133
|
setSecondary(secondaryColor);
|
20131
20134
|
setBackground(backgroundColor);
|
20135
|
+
setPrimaryAdpro(primaryColor);
|
20136
|
+
setSecondaryAdpro(secondaryColor);
|
20137
|
+
setBackgroundAdpro(backgroundColor);
|
20132
20138
|
setLoading(true);
|
20133
20139
|
});
|
20134
20140
|
}, [url]);
|
20135
20141
|
SincoTheme.palette.primary = primary;
|
20136
20142
|
SincoTheme.palette.secondary = secondary;
|
20137
20143
|
SincoTheme.palette.background = background;
|
20144
|
+
AdproSincoTheme.palette.primary = primaryAdpro;
|
20145
|
+
AdproSincoTheme.palette.secondary = secondaryAdpro;
|
20146
|
+
AdproSincoTheme.palette.background = backgroundAdpro;
|
20138
20147
|
return {
|
20139
20148
|
loading
|
20140
20149
|
};
|