@scalar/use-hooks 0.1.24 → 0.1.25
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.
|
@@ -12,10 +12,13 @@ export declare function useBreakpoints(): {
|
|
|
12
12
|
md: string;
|
|
13
13
|
lg: string;
|
|
14
14
|
xl: string;
|
|
15
|
+
zoomed: {
|
|
16
|
+
raw: string;
|
|
17
|
+
};
|
|
15
18
|
};
|
|
16
|
-
/**
|
|
17
|
-
mediaQueries: Record<"xs" | "sm" | "md" | "lg" | "xl", Ref<boolean, boolean>>;
|
|
18
|
-
/** The breakpoints as reactive
|
|
19
|
-
breakpoints: import("vue").ComputedRef<Record<"xs" | "sm" | "md" | "lg" | "xl", boolean>>;
|
|
19
|
+
/** Reactive media queries for each of the screen sizes */
|
|
20
|
+
mediaQueries: Record<"xs" | "sm" | "md" | "lg" | "xl" | "zoomed", Ref<boolean, boolean>>;
|
|
21
|
+
/** The breakpoints as reactive media queries */
|
|
22
|
+
breakpoints: import("vue").ComputedRef<Record<"xs" | "sm" | "md" | "lg" | "xl" | "zoomed", boolean>>;
|
|
20
23
|
};
|
|
21
24
|
//# sourceMappingURL=useBreakpoints.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useBreakpoints.d.ts","sourceRoot":"","sources":["../../src/useBreakpoints/useBreakpoints.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,GAAG,EAAmB,MAAM,KAAK,CAAA;AAI/C;;;;GAIG;AACH,wBAAgB,cAAc;
|
|
1
|
+
{"version":3,"file":"useBreakpoints.d.ts","sourceRoot":"","sources":["../../src/useBreakpoints/useBreakpoints.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,GAAG,EAAmB,MAAM,KAAK,CAAA;AAI/C;;;;GAIG;AACH,wBAAgB,cAAc;IAmB1B,6CAA6C;;;;;;;;;;;IAE7C,0DAA0D;;IAE1D,gDAAgD;;EAGnD"}
|
|
@@ -3,18 +3,21 @@ import { useMediaQuery as i } from "@vueuse/core";
|
|
|
3
3
|
import { computed as m, unref as c } from "vue";
|
|
4
4
|
function a() {
|
|
5
5
|
const t = o.theme.screens, s = Object.fromEntries(
|
|
6
|
-
Object.entries(t).map(([
|
|
6
|
+
Object.entries(t).map(([r, e]) => [
|
|
7
|
+
r,
|
|
8
|
+
i(typeof e == "string" ? `(min-width: ${e})` : e.raw)
|
|
9
|
+
])
|
|
7
10
|
), n = m(
|
|
8
11
|
() => Object.fromEntries(
|
|
9
|
-
Object.entries(s).map(([
|
|
12
|
+
Object.entries(s).map(([r, e]) => [r, c(e)])
|
|
10
13
|
)
|
|
11
14
|
);
|
|
12
15
|
return {
|
|
13
16
|
/** The screen sizes defined in the preset */
|
|
14
17
|
screens: t,
|
|
15
|
-
/**
|
|
18
|
+
/** Reactive media queries for each of the screen sizes */
|
|
16
19
|
mediaQueries: s,
|
|
17
|
-
/** The breakpoints as reactive
|
|
20
|
+
/** The breakpoints as reactive media queries */
|
|
18
21
|
breakpoints: n
|
|
19
22
|
};
|
|
20
23
|
}
|
package/package.json
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"url": "git+https://github.com/scalar/scalar.git",
|
|
11
11
|
"directory": "packages/use-hooks"
|
|
12
12
|
},
|
|
13
|
-
"version": "0.1.
|
|
13
|
+
"version": "0.1.25",
|
|
14
14
|
"engines": {
|
|
15
15
|
"node": ">=18"
|
|
16
16
|
},
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"@vueuse/core": "^10.10.0",
|
|
43
43
|
"vue": "^3.5.12",
|
|
44
44
|
"zod": "^3.23.8",
|
|
45
|
-
"@scalar/themes": "0.9.
|
|
45
|
+
"@scalar/themes": "0.9.71",
|
|
46
46
|
"@scalar/use-toasts": "0.7.9"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|