highsoft-ui 1.0.2 → 1.0.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.
@@ -0,0 +1 @@
1
+ export declare function useMediaQuery(query: string): boolean;
package/dist/utils.js ADDED
@@ -0,0 +1,15 @@
1
+ import { useState as r, useEffect as o } from "react";
2
+ function i(t) {
3
+ const [s, n] = r(!1);
4
+ return o(() => {
5
+ const e = window.matchMedia(t);
6
+ n(e.matches);
7
+ const a = (c) => {
8
+ n(c.matches);
9
+ };
10
+ return e.addEventListener("change", a), () => e.removeEventListener("change", a);
11
+ }, [t]), s;
12
+ }
13
+ export {
14
+ i as useMediaQuery
15
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "highsoft-ui",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "Highsoft UI",
5
5
  "type": "module",
6
6
  "main": "dist/main.js",
@@ -11,6 +11,7 @@
11
11
  "types": "./dist/main.d.ts"
12
12
  },
13
13
  "./css": "./dist/highsoft-ui.css",
14
+ "./php": "./dist/php.js",
14
15
  "./stylelint": "./stylelint.config.js"
15
16
  },
16
17
  "files": [
@@ -48,7 +49,9 @@
48
49
  "@untitled-ui/icons-react": "^0.1.4",
49
50
  "clsx": "^2.1.0",
50
51
  "highsoft-design-tokens": "^2.2.1",
51
- "modern-normalize": "^3.0.1"
52
+ "modern-normalize": "^3.0.1",
53
+ "next-themes": "^0.4.6",
54
+ "radix-ui": "^1.4.1"
52
55
  },
53
56
  "devDependencies": {
54
57
  "@babel/runtime": "^7.27.0",
@@ -1,57 +0,0 @@
1
- import { jsx as n, jsxs as c } from "react/jsx-runtime";
2
- import "react";
3
- import { c as a } from "./clsx-OuTLNxxd.js";
4
- import { Button as l } from "./components/Button/index.js";
5
- import { Container as _ } from "./components/Container/index.js";
6
- function r() {
7
- return r = Object.assign ? Object.assign.bind() : function(e) {
8
- for (var t = 1; t < arguments.length; t++) {
9
- var s = arguments[t];
10
- for (var i in s) ({}).hasOwnProperty.call(s, i) && (e[i] = s[i]);
11
- }
12
- return e;
13
- }, r.apply(null, arguments);
14
- }
15
- var p = function(t) {
16
- return /* @__PURE__ */ n("svg", r({
17
- xmlns: "http://www.w3.org/2000/svg",
18
- width: 24,
19
- height: 24,
20
- fill: "none",
21
- viewBox: "0 0 24 24"
22
- }, t, {
23
- children: /* @__PURE__ */ n("path", {
24
- stroke: "currentColor",
25
- strokeLinecap: "round",
26
- strokeLinejoin: "round",
27
- strokeWidth: 2,
28
- d: "M18 6 6 18M6 6l12 12"
29
- })
30
- }));
31
- };
32
- const d = "_notification_1psj0_17", u = "_container_1psj0_22", f = "_success_1psj0_32", m = "_danger_1psj0_37", j = "_attention_1psj0_42", g = "_title_1psj0_47", h = "_description_1psj0_53", v = "_close_1psj0_60", o = {
33
- notification: d,
34
- container: u,
35
- default: "_default_1psj0_27",
36
- success: f,
37
- danger: m,
38
- attention: j,
39
- title: g,
40
- description: h,
41
- close: v
42
- };
43
- function b({
44
- children: e,
45
- variant: t = "default",
46
- description: s
47
- }) {
48
- return /* @__PURE__ */ n("div", { className: a(o.notification, o[t]), children: /* @__PURE__ */ c(_, { className: o.container, children: [
49
- /* @__PURE__ */ n("span", { className: o.title, children: e }),
50
- s && /* @__PURE__ */ n("span", { className: o.description, children: s }),
51
- /* @__PURE__ */ n(l, { variant: "plain", size: 400, className: o.close, children: /* @__PURE__ */ n(p, {}) })
52
- ] }) });
53
- }
54
- export {
55
- b as N,
56
- r as _
57
- };