@authme/util 2.8.2 → 2.8.3

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.cjs CHANGED
@@ -1040,10 +1040,26 @@ const uiThemeButton = (dom, buttonStyle) => {
1040
1040
  dom.style.fontWeight = fontWeight[buttonStyle.textWeight];
1041
1041
  dom.style.fontSize = `${buttonStyle.fontSize}px`;
1042
1042
  dom.style.borderStyle = 'solid';
1043
- dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1043
+ // dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1044
+ dom.style.height = `48px`;
1044
1045
  dom.style.width = `calc(100% - ${buttonStyle.cornerRadius * 2}px)`;
1045
1046
  dom.style.maxWidth = `327px`;
1046
1047
  };
1048
+ const uiThemeSmallButton = (dom, buttonStyle) => {
1049
+ dom.style.borderRadius = `${buttonStyle.cornerRadius}px`;
1050
+ dom.style.backgroundColor = buttonStyle.backgroundColor;
1051
+ dom.style.opacity = buttonStyle.backgroundOpacity;
1052
+ dom.style.color = buttonStyle.textColor;
1053
+ dom.style.borderColor = hexToRgba(buttonStyle.borderColor, buttonStyle.borderOpacity);
1054
+ dom.style.borderWidth = `${buttonStyle.borderWidth}px`;
1055
+ dom.style.fontWeight = fontWeight[buttonStyle.textWeight];
1056
+ dom.style.fontSize = `${buttonStyle.fontSize}px`;
1057
+ dom.style.borderStyle = 'solid';
1058
+ // dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1059
+ dom.style.height = `30px`;
1060
+ dom.style.width = `calc(100% - ${buttonStyle.cornerRadius * 2}px)`;
1061
+ dom.style.maxWidth = `106px`;
1062
+ };
1047
1063
 
1048
1064
  function startSpinner(args) {
1049
1065
  const loadingLottie = Storage.getItem(exports.STORAGE_KEY.LOADING_LOTTIE);
@@ -2966,8 +2982,8 @@ const themeConfigDefault = {
2966
2982
  };
2967
2983
 
2968
2984
  var name = "authme/sdk";
2969
- var version$1 = "2.8.2";
2970
- var date = "2025-02-26T06:47:43+0000";
2985
+ var version$1 = "2.8.3";
2986
+ var date = "2025-03-05T06:16:55+0000";
2971
2987
  var packageInfo = {
2972
2988
  name: name,
2973
2989
  version: version$1,
@@ -3028,6 +3044,7 @@ exports.switchCamera = switchCamera;
3028
3044
  exports.themeConfigDefault = themeConfigDefault;
3029
3045
  exports.uiThemeButton = uiThemeButton;
3030
3046
  exports.uiThemeHint = uiThemeHint;
3047
+ exports.uiThemeSmallButton = uiThemeSmallButton;
3031
3048
  exports.uiThemeText = uiThemeText;
3032
3049
  exports.uploadModal = uploadModal;
3033
3050
  exports.useState = useState;
package/index.js CHANGED
@@ -1030,10 +1030,26 @@ const uiThemeButton = (dom, buttonStyle) => {
1030
1030
  dom.style.fontWeight = fontWeight[buttonStyle.textWeight];
1031
1031
  dom.style.fontSize = `${buttonStyle.fontSize}px`;
1032
1032
  dom.style.borderStyle = 'solid';
1033
- dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1033
+ // dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1034
+ dom.style.height = `48px`;
1034
1035
  dom.style.width = `calc(100% - ${buttonStyle.cornerRadius * 2}px)`;
1035
1036
  dom.style.maxWidth = `327px`;
1036
1037
  };
1038
+ const uiThemeSmallButton = (dom, buttonStyle) => {
1039
+ dom.style.borderRadius = `${buttonStyle.cornerRadius}px`;
1040
+ dom.style.backgroundColor = buttonStyle.backgroundColor;
1041
+ dom.style.opacity = buttonStyle.backgroundOpacity;
1042
+ dom.style.color = buttonStyle.textColor;
1043
+ dom.style.borderColor = hexToRgba(buttonStyle.borderColor, buttonStyle.borderOpacity);
1044
+ dom.style.borderWidth = `${buttonStyle.borderWidth}px`;
1045
+ dom.style.fontWeight = fontWeight[buttonStyle.textWeight];
1046
+ dom.style.fontSize = `${buttonStyle.fontSize}px`;
1047
+ dom.style.borderStyle = 'solid';
1048
+ // dom.style.height = `${buttonStyle.cornerRadius * 2}px`;
1049
+ dom.style.height = `30px`;
1050
+ dom.style.width = `calc(100% - ${buttonStyle.cornerRadius * 2}px)`;
1051
+ dom.style.maxWidth = `106px`;
1052
+ };
1037
1053
 
1038
1054
  function startSpinner(args) {
1039
1055
  const loadingLottie = Storage.getItem(STORAGE_KEY.LOADING_LOTTIE);
@@ -2956,8 +2972,8 @@ const themeConfigDefault = {
2956
2972
  };
2957
2973
 
2958
2974
  var name = "authme/sdk";
2959
- var version$1 = "2.8.2";
2960
- var date = "2025-02-26T06:47:43+0000";
2975
+ var version$1 = "2.8.3";
2976
+ var date = "2025-03-05T06:16:55+0000";
2961
2977
  var packageInfo = {
2962
2978
  name: name,
2963
2979
  version: version$1,
@@ -2970,4 +2986,4 @@ const version = packageInfo.version;
2970
2986
  (_a = (_b = window)[_c = Symbol.for('authme-sdk')]) !== null && _a !== void 0 ? _a : _b[_c] = {};
2971
2987
  window[Symbol.for('authme-sdk')][packageInfo.name] = version;
2972
2988
 
2973
- export { AuthmeError, ErrorCode, Icon, RGBToLottieColor, RUN_FUNCTION_NAME, STORAGE_KEY, Storage, TIME_UNIT, UintArrayToBlob, asyncOnLineShowErrorMessage, asyncShowErrorMessage, asyncShowPopup, backgroundRequest, checkOnlineStatus, clearCanvas, colorStringToRGB, colorToRGB, combineResult, cropByRatio, dataURItoBlob, debugLog, debugTools, decodeToken, fontWeight, getCanvasSize, getCssVariable, getDeviceInfo, getImageData, getSystemInfo, hexToRGB, hideElement, hideErrorMessage, hidePopup, isIphone14proOrProMax, isMobile, isMobileOrTablet, osVersion, requestCamera, resize, retryPromiseWithCondition, showElement, showErrorMessage, showErrorMessageEventName, showPopup, splitResult, startLoadingSDK, startSpinner, stopLoadingSDK, stopSpinner, switchCamera, themeConfigDefault, uiThemeButton, uiThemeHint, uiThemeText, uploadModal, useState, verificationErrorMessages, version, videoConstraintsFactory, waitTime };
2989
+ export { AuthmeError, ErrorCode, Icon, RGBToLottieColor, RUN_FUNCTION_NAME, STORAGE_KEY, Storage, TIME_UNIT, UintArrayToBlob, asyncOnLineShowErrorMessage, asyncShowErrorMessage, asyncShowPopup, backgroundRequest, checkOnlineStatus, clearCanvas, colorStringToRGB, colorToRGB, combineResult, cropByRatio, dataURItoBlob, debugLog, debugTools, decodeToken, fontWeight, getCanvasSize, getCssVariable, getDeviceInfo, getImageData, getSystemInfo, hexToRGB, hideElement, hideErrorMessage, hidePopup, isIphone14proOrProMax, isMobile, isMobileOrTablet, osVersion, requestCamera, resize, retryPromiseWithCondition, showElement, showErrorMessage, showErrorMessageEventName, showPopup, splitResult, startLoadingSDK, startSpinner, stopLoadingSDK, stopSpinner, switchCamera, themeConfigDefault, uiThemeButton, uiThemeHint, uiThemeSmallButton, uiThemeText, uploadModal, useState, verificationErrorMessages, version, videoConstraintsFactory, waitTime };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@authme/util",
3
- "version": "2.8.2",
3
+ "version": "2.8.3",
4
4
  "peerDependencies": {
5
5
  "core-js": "^3.6.0",
6
6
  "jwt-decode": "3.1.2",
@@ -2,3 +2,4 @@ export declare const fontWeight: any;
2
2
  export declare const uiThemeText: (dom: any, textStyle: any) => void;
3
3
  export declare const uiThemeHint: (dom: any, hintStyle: any) => void;
4
4
  export declare const uiThemeButton: (dom: any, buttonStyle: any) => void;
5
+ export declare const uiThemeSmallButton: (dom: any, buttonStyle: any) => void;