@abpjs/theme-basic 3.0.0 → 3.2.0

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.
@@ -27,5 +27,5 @@ export interface NavItemsComponentProps {
27
27
  * <NavItemsComponent smallScreen />
28
28
  * ```
29
29
  */
30
- export declare function NavItemsComponent({ smallScreen, }: NavItemsComponentProps): React.ReactElement;
30
+ export declare function NavItemsComponent({ smallScreen: _smallScreen, }: NavItemsComponentProps): React.ReactElement;
31
31
  export default NavItemsComponent;
package/dist/index.d.ts CHANGED
@@ -2,10 +2,16 @@
2
2
  * @abpjs/theme-basic
3
3
  *
4
4
  * ABP Framework Theme Basic components for React.
5
- * Translated from @abp/ng.theme.basic v3.0.0
5
+ * Translated from @abp/ng.theme.basic v3.2.0
6
6
  *
7
7
  * This package provides the basic theme layout components for ABP React applications.
8
8
  *
9
+ * Changes in v3.2.0:
10
+ * - Reduced .abp-loading background opacity from 0.1 to 0.05 for better UX
11
+ * - Angular: RoutesComponent added closeDropdown() method (React handles via state/events)
12
+ * - Angular: StylesProvider now uses ReplaceableComponentsService instead of Store (React uses hooks)
13
+ * - Dependency update to @abp/ng.theme.shared v3.2.0
14
+ *
9
15
  * Changes in v3.0.0:
10
16
  * - Added CurrentUserComponent and LanguagesComponent as public API components
11
17
  * - Added nav-item.provider and styles.provider for initialization
@@ -45,7 +51,7 @@
45
51
  * - Dependency update to @abp/ng.theme.shared v2.2.0
46
52
  * - No functional code changes
47
53
  *
48
- * @version 3.0.0
54
+ * @version 3.2.0
49
55
  * @since 2.0.0 - Removed legacy .abp-confirm styles (no impact on React - we use Chakra UI)
50
56
  * @since 2.1.0 - Angular: OAuthService replaced with AuthService (already using useAuth in React)
51
57
  * - Angular: Added styles for loading, modal-backdrop, confirmation (handled by Chakra UI)
package/dist/index.js CHANGED
@@ -1035,10 +1035,10 @@ var import_react22 = require("@chakra-ui/react");
1035
1035
  var import_theme_shared3 = require("@abpjs/theme-shared");
1036
1036
  var import_jsx_runtime18 = require("react/jsx-runtime");
1037
1037
  function NavItemsComponent({
1038
- smallScreen = false
1038
+ smallScreen: _smallScreen = false
1039
1039
  }) {
1040
1040
  const navItems = (0, import_theme_shared3.useNavItems)();
1041
- const trackByFn = (0, import_react21.useCallback)((item) => {
1041
+ const _trackByFn = (0, import_react21.useCallback)((item) => {
1042
1042
  return item.id;
1043
1043
  }, []);
1044
1044
  const renderNavItem = (0, import_react21.useCallback)((item) => {
@@ -1173,7 +1173,7 @@ function LanguagesComponent({
1173
1173
  const dropdownLanguages = (0, import_react25.useMemo)(() => {
1174
1174
  return languages.filter((lang) => lang.cultureName !== language);
1175
1175
  }, [languages, language]);
1176
- const selectedLangCulture = language || "";
1176
+ const _selectedLangCulture = language || "";
1177
1177
  const handleChangeLang = (0, import_react25.useCallback)(
1178
1178
  (cultureName) => {
1179
1179
  setLanguage(cultureName);
@@ -1453,9 +1453,9 @@ var THEME_BASIC_STYLES = `
1453
1453
  margin-top: -1px;
1454
1454
  }
1455
1455
 
1456
- /* Loading overlay */
1456
+ /* Loading overlay (v3.2.0: reduced opacity from 0.1 to 0.05) */
1457
1457
  .abp-loading {
1458
- background: rgba(0, 0, 0, 0.1);
1458
+ background: rgba(0, 0, 0, 0.05);
1459
1459
  }
1460
1460
 
1461
1461
  /* Modal backdrop */
package/dist/index.mjs CHANGED
@@ -978,10 +978,10 @@ import { Stack as Stack3, Box as Box9 } from "@chakra-ui/react";
978
978
  import { useNavItems } from "@abpjs/theme-shared";
979
979
  import { jsx as jsx18 } from "react/jsx-runtime";
980
980
  function NavItemsComponent({
981
- smallScreen = false
981
+ smallScreen: _smallScreen = false
982
982
  }) {
983
983
  const navItems = useNavItems();
984
- const trackByFn = useCallback4((item) => {
984
+ const _trackByFn = useCallback4((item) => {
985
985
  return item.id;
986
986
  }, []);
987
987
  const renderNavItem = useCallback4((item) => {
@@ -1108,7 +1108,7 @@ import {
1108
1108
  Text as Text6
1109
1109
  } from "@chakra-ui/react";
1110
1110
  import { LuChevronDown as LuChevronDown3, LuGlobe as LuGlobe2 } from "react-icons/lu";
1111
- import { useConfig as useConfig5, useSession as useSession3 } from "@abpjs/core";
1111
+ import { useConfig as useConfig5, useSession as useSession2 } from "@abpjs/core";
1112
1112
  import { jsx as jsx20, jsxs as jsxs13 } from "react/jsx-runtime";
1113
1113
  function LanguagesComponent({
1114
1114
  smallScreen: _smallScreen = false,
@@ -1117,7 +1117,7 @@ function LanguagesComponent({
1117
1117
  menuZIndex = 1400
1118
1118
  }) {
1119
1119
  const { localization } = useConfig5();
1120
- const { language, setLanguage } = useSession3();
1120
+ const { language, setLanguage } = useSession2();
1121
1121
  const languages = useMemo7(() => {
1122
1122
  return localization?.languages || [];
1123
1123
  }, [localization]);
@@ -1130,7 +1130,7 @@ function LanguagesComponent({
1130
1130
  const dropdownLanguages = useMemo7(() => {
1131
1131
  return languages.filter((lang) => lang.cultureName !== language);
1132
1132
  }, [languages, language]);
1133
- const selectedLangCulture = language || "";
1133
+ const _selectedLangCulture = language || "";
1134
1134
  const handleChangeLang = useCallback6(
1135
1135
  (cultureName) => {
1136
1136
  setLanguage(cultureName);
@@ -1211,14 +1211,14 @@ function RoutesComponent({
1211
1211
  }
1212
1212
 
1213
1213
  // src/providers/ThemeBasicProvider.tsx
1214
- import { useEffect as useEffect2 } from "react";
1214
+ import { useEffect } from "react";
1215
1215
  import { ThemeSharedProvider, defineConfig } from "@abpjs/theme-shared";
1216
- import { useSession as useSession4, useDirection as useDirection8 } from "@abpjs/core";
1216
+ import { useSession as useSession3, useDirection as useDirection8 } from "@abpjs/core";
1217
1217
  import { Fragment as Fragment4, jsx as jsx22 } from "react/jsx-runtime";
1218
1218
  function LocaleSync({ children }) {
1219
- const { language } = useSession4();
1219
+ const { language } = useSession3();
1220
1220
  const { direction } = useDirection8();
1221
- useEffect2(() => {
1221
+ useEffect(() => {
1222
1222
  document.documentElement.dir = direction;
1223
1223
  document.documentElement.lang = language || "en";
1224
1224
  }, [direction, language]);
@@ -1237,7 +1237,7 @@ function ThemeBasicInner({
1237
1237
  appName,
1238
1238
  logoLink
1239
1239
  }) {
1240
- const { language } = useSession4();
1240
+ const { language } = useSession3();
1241
1241
  const locale = language || "en-US";
1242
1242
  return /* @__PURE__ */ jsx22(
1243
1243
  ThemeSharedProvider,
@@ -1410,9 +1410,9 @@ var THEME_BASIC_STYLES = `
1410
1410
  margin-top: -1px;
1411
1411
  }
1412
1412
 
1413
- /* Loading overlay */
1413
+ /* Loading overlay (v3.2.0: reduced opacity from 0.1 to 0.05) */
1414
1414
  .abp-loading {
1415
- background: rgba(0, 0, 0, 0.1);
1415
+ background: rgba(0, 0, 0, 0.05);
1416
1416
  }
1417
1417
 
1418
1418
  /* Modal backdrop */
@@ -15,7 +15,7 @@
15
15
  *
16
16
  * @since 3.0.0
17
17
  */
18
- export declare const THEME_BASIC_STYLES = "\n/* Content header styles */\n.content-header-title {\n font-size: 24px;\n}\n\n.entry-row {\n margin-bottom: 15px;\n}\n\n/* Input validation styles */\n.input-validation-error {\n border-color: #dc3545;\n}\n\n.field-validation-error {\n font-size: 0.8em;\n}\n\n/* Table styles */\n.ui-table .ui-table-tbody > tr.empty-row > div.empty-row-content {\n border: 1px solid #c8c8c8;\n}\n\n.ui-table .pagination-wrapper {\n background-color: #f4f4f4;\n border: 1px solid #c8c8c8;\n}\n\n/* Bordered datatable styles (added in v3.0.0) */\n.bordered .datatable-body-row {\n border-top: 1px solid #eee;\n margin-top: -1px;\n}\n\n/* Loading overlay */\n.abp-loading {\n background: rgba(0, 0, 0, 0.1);\n}\n\n/* Modal backdrop */\n.modal-backdrop {\n background-color: rgba(0, 0, 0, 0.6);\n}\n";
18
+ export declare const THEME_BASIC_STYLES = "\n/* Content header styles */\n.content-header-title {\n font-size: 24px;\n}\n\n.entry-row {\n margin-bottom: 15px;\n}\n\n/* Input validation styles */\n.input-validation-error {\n border-color: #dc3545;\n}\n\n.field-validation-error {\n font-size: 0.8em;\n}\n\n/* Table styles */\n.ui-table .ui-table-tbody > tr.empty-row > div.empty-row-content {\n border: 1px solid #c8c8c8;\n}\n\n.ui-table .pagination-wrapper {\n background-color: #f4f4f4;\n border: 1px solid #c8c8c8;\n}\n\n/* Bordered datatable styles (added in v3.0.0) */\n.bordered .datatable-body-row {\n border-top: 1px solid #eee;\n margin-top: -1px;\n}\n\n/* Loading overlay (v3.2.0: reduced opacity from 0.1 to 0.05) */\n.abp-loading {\n background: rgba(0, 0, 0, 0.05);\n}\n\n/* Modal backdrop */\n.modal-backdrop {\n background-color: rgba(0, 0, 0, 0.6);\n}\n";
19
19
  /**
20
20
  * Injects the theme-basic styles into the document head.
21
21
  * Call this function during app initialization if you need the global CSS styles.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abpjs/theme-basic",
3
- "version": "3.0.0",
3
+ "version": "3.2.0",
4
4
  "description": "ABP Framework Theme Basic components for React - translated from @abp/ng.theme.basic",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -27,11 +27,11 @@
27
27
  "lucide-react": "^0.400.0",
28
28
  "react-hook-form": "^7.48.0",
29
29
  "react-icons": "^5.0.0",
30
- "@abpjs/core": "3.0.0",
31
- "@abpjs/theme-shared": "3.0.0"
30
+ "@abpjs/core": "3.2.0",
31
+ "@abpjs/theme-shared": "3.2.0"
32
32
  },
33
33
  "devDependencies": {
34
- "@abp/ng.theme.basic": "3.0.0",
34
+ "@abp/ng.theme.basic": "3.2.0",
35
35
  "@testing-library/jest-dom": "^6.6.3",
36
36
  "@testing-library/react": "^16.1.0",
37
37
  "@vitest/coverage-v8": "^1.6.0",