diff --git a/.gitignore b/.gitignore index 7586c68..4f37e14 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,6 @@ # Dependencies node_modules/ -# Build output -dist/ - # IDE .vscode/ .idea/ diff --git a/dist/homeassistant.d.ts b/dist/homeassistant.d.ts new file mode 100644 index 0000000..4032f4b --- /dev/null +++ b/dist/homeassistant.d.ts @@ -0,0 +1,25 @@ +export type HomeAssistantEntity = { + entity_id: string; + state: string; + attributes: { + state_class?: string; + unit_of_measurement?: string; + icon?: string; + friendly_name?: string; + [key: string]: unknown; + }; + last_changed: string; + last_reported: string; + last_updated: string; + context: { + id: string; + parent_id: string | null; + user_id: string | null; + }; +}; +export interface HomeAssistantDeskPositionResult { + raw: HomeAssistantEntity; + asBoolean: boolean; + asText: () => string; +} +//# sourceMappingURL=homeassistant.d.ts.map \ No newline at end of file diff --git a/dist/homeassistant.d.ts.map b/dist/homeassistant.d.ts.map new file mode 100644 index 0000000..5fcc155 --- /dev/null +++ b/dist/homeassistant.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"homeassistant.d.ts","sourceRoot":"","sources":["../src/homeassistant.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAAG;IAChC,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE;QACV,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,mBAAmB,CAAC,EAAE,MAAM,CAAC;QAC7B,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,aAAa,CAAC,EAAE,MAAM,CAAC;QACvB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;KACxB,CAAC;IACF,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE;QACP,EAAE,EAAE,MAAM,CAAC;QACX,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;QACzB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;KACxB,CAAC;CACH,CAAC;AAEF,MAAM,WAAW,+BAA+B;IAC9C,GAAG,EAAE,mBAAmB,CAAC;IACzB,SAAS,EAAE,OAAO,CAAC;IACnB,MAAM,EAAE,MAAM,MAAM,CAAC;CACtB"} \ No newline at end of file diff --git a/dist/homeassistant.js b/dist/homeassistant.js new file mode 100644 index 0000000..c8ad2e5 --- /dev/null +++ b/dist/homeassistant.js @@ -0,0 +1,2 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/index.d.ts b/dist/index.d.ts new file mode 100644 index 0000000..57053c2 --- /dev/null +++ b/dist/index.d.ts @@ -0,0 +1,3 @@ +export * from "./homeassistant"; +export * from "./tidal"; +//# sourceMappingURL=index.d.ts.map \ No newline at end of file diff --git a/dist/index.d.ts.map b/dist/index.d.ts.map new file mode 100644 index 0000000..ccfc105 --- /dev/null +++ b/dist/index.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC"} \ No newline at end of file diff --git a/dist/index.js b/dist/index.js new file mode 100644 index 0000000..fab5ae1 --- /dev/null +++ b/dist/index.js @@ -0,0 +1,18 @@ +"use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __exportStar = (this && this.__exportStar) || function(m, exports) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +__exportStar(require("./homeassistant"), exports); +__exportStar(require("./tidal"), exports); diff --git a/dist/tidal.d.ts b/dist/tidal.d.ts new file mode 100644 index 0000000..bbd8379 --- /dev/null +++ b/dist/tidal.d.ts @@ -0,0 +1,14 @@ +export type TidalSong = { + title: string; + artists: string; + album: string; + playingFrom: string; + status: "playing" | "paused"; + url: string; + current: string; + duration: string; +}; +export type TidalVolume = { + volume: number; +}; +//# sourceMappingURL=tidal.d.ts.map \ No newline at end of file diff --git a/dist/tidal.d.ts.map b/dist/tidal.d.ts.map new file mode 100644 index 0000000..2877cad --- /dev/null +++ b/dist/tidal.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"tidal.d.ts","sourceRoot":"","sources":["../src/tidal.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC7B,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC"} \ No newline at end of file diff --git a/dist/tidal.js b/dist/tidal.js new file mode 100644 index 0000000..c8ad2e5 --- /dev/null +++ b/dist/tidal.js @@ -0,0 +1,2 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/types.d.ts b/dist/types.d.ts new file mode 100644 index 0000000..550b211 --- /dev/null +++ b/dist/types.d.ts @@ -0,0 +1,40 @@ +export interface User { + id: string; + email: string; + name: string; + createdAt: Date; + updatedAt: Date; +} +export interface UserProfile extends User { + bio?: string; + avatarUrl?: string; +} +export interface ApiResponse { + success: boolean; + data?: T; + error?: string; + message?: string; +} +export interface PaginatedResponse extends ApiResponse { + page: number; + pageSize: number; + totalPages: number; + totalItems: number; +} +export type Nullable = T | null; +export type Optional = T | undefined; +export type ID = string | number; +export declare enum Status { + Active = "active", + Inactive = "inactive", + Pending = "pending", + Archived = "archived" +} +export declare enum HttpMethod { + GET = "GET", + POST = "POST", + PUT = "PUT", + PATCH = "PATCH", + DELETE = "DELETE" +} +//# sourceMappingURL=types.d.ts.map \ No newline at end of file diff --git a/dist/types.d.ts.map b/dist/types.d.ts.map new file mode 100644 index 0000000..5cd80bf --- /dev/null +++ b/dist/types.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,IAAI;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,IAAI,CAAC;IAChB,SAAS,EAAE,IAAI,CAAC;CACjB;AAED,MAAM,WAAW,WAAY,SAAQ,IAAI;IACvC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAGD,MAAM,WAAW,WAAW,CAAC,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,CAAC,CAAC;IACT,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,iBAAiB,CAAC,CAAC,CAAE,SAAQ,WAAW,CAAC,CAAC,EAAE,CAAC;IAC5D,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAGD,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;AACnC,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI,CAAC,GAAG,SAAS,CAAC;AACxC,MAAM,MAAM,EAAE,GAAG,MAAM,GAAG,MAAM,CAAC;AAGjC,oBAAY,MAAM;IAChB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,OAAO,YAAY;IACnB,QAAQ,aAAa;CACtB;AAED,oBAAY,UAAU;IACpB,GAAG,QAAQ;IACX,IAAI,SAAS;IACb,GAAG,QAAQ;IACX,KAAK,UAAU;IACf,MAAM,WAAW;CAClB"} \ No newline at end of file diff --git a/dist/types.js b/dist/types.js new file mode 100644 index 0000000..4e3d627 --- /dev/null +++ b/dist/types.js @@ -0,0 +1,19 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.HttpMethod = exports.Status = void 0; +// Status enums +var Status; +(function (Status) { + Status["Active"] = "active"; + Status["Inactive"] = "inactive"; + Status["Pending"] = "pending"; + Status["Archived"] = "archived"; +})(Status || (exports.Status = Status = {})); +var HttpMethod; +(function (HttpMethod) { + HttpMethod["GET"] = "GET"; + HttpMethod["POST"] = "POST"; + HttpMethod["PUT"] = "PUT"; + HttpMethod["PATCH"] = "PATCH"; + HttpMethod["DELETE"] = "DELETE"; +})(HttpMethod || (exports.HttpMethod = HttpMethod = {}));