@etsoo/smarterp-core 1.0.76 → 1.0.77

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.
@@ -1,4 +1,11 @@
1
1
  /**
2
2
  * Core utilities
3
3
  */
4
- export declare namespace CoreUtils { }
4
+ export declare namespace CoreUtils {
5
+ /**
6
+ * Get avatar styles
7
+ * @param isOrg Is this an organization avatar?
8
+ * @returns Styles
9
+ */
10
+ function avatarStyles(isOrg?: boolean): React.CSSProperties;
11
+ }
@@ -1,2 +1,22 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CoreUtils = void 0;
4
+ /**
5
+ * Core utilities
6
+ */
7
+ var CoreUtils;
8
+ (function (CoreUtils) {
9
+ /**
10
+ * Get avatar styles
11
+ * @param isOrg Is this an organization avatar?
12
+ * @returns Styles
13
+ */
14
+ function avatarStyles(isOrg = false) {
15
+ return {
16
+ width: "160px",
17
+ height: isOrg ? "80px" : "160px",
18
+ border: "1px solid #666"
19
+ };
20
+ }
21
+ CoreUtils.avatarStyles = avatarStyles;
22
+ })(CoreUtils || (exports.CoreUtils = CoreUtils = {}));
@@ -1,4 +1,11 @@
1
1
  /**
2
2
  * Core utilities
3
3
  */
4
- export declare namespace CoreUtils { }
4
+ export declare namespace CoreUtils {
5
+ /**
6
+ * Get avatar styles
7
+ * @param isOrg Is this an organization avatar?
8
+ * @returns Styles
9
+ */
10
+ function avatarStyles(isOrg?: boolean): React.CSSProperties;
11
+ }
@@ -1 +1,19 @@
1
- export {};
1
+ /**
2
+ * Core utilities
3
+ */
4
+ export var CoreUtils;
5
+ (function (CoreUtils) {
6
+ /**
7
+ * Get avatar styles
8
+ * @param isOrg Is this an organization avatar?
9
+ * @returns Styles
10
+ */
11
+ function avatarStyles(isOrg = false) {
12
+ return {
13
+ width: "160px",
14
+ height: isOrg ? "80px" : "160px",
15
+ border: "1px solid #666"
16
+ };
17
+ }
18
+ CoreUtils.avatarStyles = avatarStyles;
19
+ })(CoreUtils || (CoreUtils = {}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/smarterp-core",
3
- "version": "1.0.76",
3
+ "version": "1.0.77",
4
4
  "description": "TypeScript APIs for SmartERP Core",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
package/src/CoreUtils.ts CHANGED
@@ -1,4 +1,17 @@
1
1
  /**
2
2
  * Core utilities
3
3
  */
4
- export namespace CoreUtils {}
4
+ export namespace CoreUtils {
5
+ /**
6
+ * Get avatar styles
7
+ * @param isOrg Is this an organization avatar?
8
+ * @returns Styles
9
+ */
10
+ export function avatarStyles(isOrg: boolean = false): React.CSSProperties {
11
+ return {
12
+ width: "160px",
13
+ height: isOrg ? "80px" : "160px",
14
+ border: "1px solid #666"
15
+ };
16
+ }
17
+ }