@homebridge-plugins/homebridge-sharkiq 1.3.2

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.
Files changed (75) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/LICENSE +176 -0
  3. package/README.md +92 -0
  4. package/config.schema.json +114 -0
  5. package/dist/config.d.ts +7 -0
  6. package/dist/config.d.ts.map +1 -0
  7. package/dist/config.js +131 -0
  8. package/dist/config.js.map +1 -0
  9. package/dist/homebridge-ui/public/index.html +201 -0
  10. package/dist/homebridge-ui/server.d.ts +2 -0
  11. package/dist/homebridge-ui/server.d.ts.map +1 -0
  12. package/dist/homebridge-ui/server.js +47 -0
  13. package/dist/homebridge-ui/server.js.map +1 -0
  14. package/dist/index.d.ts +4 -0
  15. package/dist/index.d.ts.map +1 -0
  16. package/dist/index.js +7 -0
  17. package/dist/index.js.map +1 -0
  18. package/dist/login.d.ts +16 -0
  19. package/dist/login.d.ts.map +1 -0
  20. package/dist/login.js +242 -0
  21. package/dist/login.js.map +1 -0
  22. package/dist/platform.d.ts +16 -0
  23. package/dist/platform.d.ts.map +1 -0
  24. package/dist/platform.js +118 -0
  25. package/dist/platform.js.map +1 -0
  26. package/dist/platformAccessory.d.ts +29 -0
  27. package/dist/platformAccessory.d.ts.map +1 -0
  28. package/dist/platformAccessory.js +285 -0
  29. package/dist/platformAccessory.js.map +1 -0
  30. package/dist/settings.d.ts +3 -0
  31. package/dist/settings.d.ts.map +1 -0
  32. package/dist/settings.js +3 -0
  33. package/dist/settings.js.map +1 -0
  34. package/dist/sharkiq-js/ayla_api.d.ts +39 -0
  35. package/dist/sharkiq-js/ayla_api.d.ts.map +1 -0
  36. package/dist/sharkiq-js/ayla_api.js +289 -0
  37. package/dist/sharkiq-js/ayla_api.js.map +1 -0
  38. package/dist/sharkiq-js/const.d.ts +22 -0
  39. package/dist/sharkiq-js/const.d.ts.map +1 -0
  40. package/dist/sharkiq-js/const.js +23 -0
  41. package/dist/sharkiq-js/const.js.map +1 -0
  42. package/dist/sharkiq-js/properties.d.ts +52 -0
  43. package/dist/sharkiq-js/properties.d.ts.map +1 -0
  44. package/dist/sharkiq-js/properties.js +56 -0
  45. package/dist/sharkiq-js/properties.js.map +1 -0
  46. package/dist/sharkiq-js/sharkiq.d.ts +59 -0
  47. package/dist/sharkiq-js/sharkiq.d.ts.map +1 -0
  48. package/dist/sharkiq-js/sharkiq.js +359 -0
  49. package/dist/sharkiq-js/sharkiq.js.map +1 -0
  50. package/dist/type.d.ts +12 -0
  51. package/dist/type.d.ts.map +1 -0
  52. package/dist/type.js +2 -0
  53. package/dist/type.js.map +1 -0
  54. package/dist/utils.d.ts +10 -0
  55. package/dist/utils.d.ts.map +1 -0
  56. package/dist/utils.js +35 -0
  57. package/dist/utils.js.map +1 -0
  58. package/docs/.nojekyll +1 -0
  59. package/docs/assets/dmt/dmt-component-data.js +1 -0
  60. package/docs/assets/dmt/dmt-components.css +20 -0
  61. package/docs/assets/dmt/dmt-components.js +67 -0
  62. package/docs/assets/dmt/dmt-search.cmp +0 -0
  63. package/docs/assets/dmt/dmt-theme.css +1 -0
  64. package/docs/assets/hierarchy.js +1 -0
  65. package/docs/assets/highlight.css +57 -0
  66. package/docs/assets/icons.js +18 -0
  67. package/docs/assets/icons.svg +1 -0
  68. package/docs/assets/main.js +60 -0
  69. package/docs/assets/style.css +1611 -0
  70. package/docs/functions/default.html +2 -0
  71. package/docs/index.html +50 -0
  72. package/docs/modules.html +2 -0
  73. package/eslint.config.js +49 -0
  74. package/package.json +87 -0
  75. package/typedoc.json +21 -0
@@ -0,0 +1,2 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base=".."><head><style>body { visibility: hidden; }</style><meta charset="utf-8"><meta http-equiv="x-ua-compatible" content="IE=edge"><title>default | @homebridge-plugins/homebridge-sharkiq</title><meta name="description" content="Documentation for @homebridge-plugins/homebridge-sharkiq"><meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="../assets/style.css"><link rel="stylesheet" href="../assets/highlight.css"><script defer="" src="../assets/main.js"></script><script async="" src="../assets/icons.js" id="tsd-icons-script"></script><link rel="stylesheet" href="../assets/dmt/dmt-components.css"><link rel="stylesheet" href="../assets/dmt/dmt-theme.css"><script src="../assets/dmt/dmt-components.js" type="module"></script><noscript><style>body { visibility: visible; }</style></noscript></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";</script><div class="overlay"></div>
2
+ <main><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field" id="dmt-search-main"></div><div class="field" id="dmt-toolbar"><a href="../index.html" class="title">@homebridge-plugins/homebridge-sharkiq</a></div></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main" tabindex="-1"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"></ul><div class="dmt-title-header-flex"><h1>Function default</h1></div></div><section class="tsd-panel"><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link"><a id="default" class="tsd-anchor"></a><span class="tsd-kind-call-signature">default</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">api</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">API</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#default" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">api</span>: <span class="tsd-signature-type">API</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge-plugins/homebridge-sharkiq/blob/d392eb4532880284cf52cf10ae14c336a0c6b9f3/src/index.ts#L7">index.ts:7</a></li></ul></aside></div></li></ul></section></div><div class="col-sidebar" tabindex="-1"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked=""><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu" tabindex="-1"><nav class="tsd-navigation"><a href="../modules.html">@homebridge-plugins/homebridge-sharkiq</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"></ul></nav></div></div></div></main></body></html>
@@ -0,0 +1,50 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="."><head><style>body { visibility: hidden; }</style><meta charset="utf-8"><meta http-equiv="x-ua-compatible" content="IE=edge"><title>@homebridge-plugins/homebridge-sharkiq</title><meta name="description" content="Documentation for @homebridge-plugins/homebridge-sharkiq"><meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="assets/style.css"><link rel="stylesheet" href="assets/highlight.css"><script defer="" src="assets/main.js"></script><script async="" src="assets/icons.js" id="tsd-icons-script"></script><link rel="stylesheet" href="assets/dmt/dmt-components.css"><link rel="stylesheet" href="assets/dmt/dmt-theme.css"><script src="assets/dmt/dmt-components.js" type="module"></script><noscript><style>body { visibility: visible; }</style></noscript></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";</script><div class="overlay"></div>
2
+ <main><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field" id="dmt-search-main"></div><div class="field" id="dmt-toolbar"><a href="index.html" class="title">@homebridge-plugins/homebridge-sharkiq</a></div></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main" tabindex="-1"><div class="col-content"><div class="tsd-page-title"><div class="dmt-title-header-flex"><h1>@homebridge-plugins/homebridge-sharkiq</h1></div></div><div class="tsd-panel tsd-typography"><span align="center">
3
+ <a id="homebridge-shark-clean-vacuum-plugin" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Homebridge Shark Clean Vacuum Plugin<a href="#homebridge-shark-clean-vacuum-plugin" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h1><p><a href="https://github.com/homebridge/homebridge/wiki/Verified-Plugins"><img src="https://badgen.net/badge/homebridge/verified/purple" alt="verified-by-homebridge"></a>
4
+ <a href="https://www.npmjs.com/package/homebridge-sharkiq"><img src="https://badgen.net/npm/dt/homebridge-sharkiq?color=purple" alt="npm"></a>
5
+ <a href="https://www.npmjs.com/package/homebridge-sharkiq"><img src="https://badgen.net/npm/v/homebridge-sharkiq?color=purple" alt="npm"></a></p>
6
+ </span>
7
+ <p>A new homebridge plugin for SharkIQ Vacuums.</p>
8
+ <p>Contributions are always welcome. I used the <a href="https://github.com/JeffResc/sharkiq/">sharkiq</a> python module as a reference for creating the javascript wrapper to control SharkIQ Vacuums.</p>
9
+ <p>This plguin has only been tested on the <code>UR250BEXUS</code> model.</p>
10
+ <p>The fastest way to get community support (not for bugs) is to join the <a href="https://discord.gg/kqNCe2D">Homebridge Discord server</a> and chat in the #sharkiq channel.</p>
11
+ <a id="install-and-setup" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Install and Setup<a href="#install-and-setup" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2><a id="step-1" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Step 1.<a href="#step-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Run <code>npm install -g homebridge-sharkiq</code></p>
12
+ <a id="step-2" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Step 2.<a href="#step-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Configure Homebridge. The config file for SharkIQ should include:</p>
13
+ <pre><code class="json"><span class="hl-0">{</span><br><span class="hl-0"> </span><span class="hl-1">"platforms"</span><span class="hl-0">: [</span><br><span class="hl-0"> {</span><br><span class="hl-0"> </span><span class="hl-1">"name"</span><span class="hl-0">: </span><span class="hl-2">"SharkIQ"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"platform"</span><span class="hl-0">: </span><span class="hl-2">"SharkIQ"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"email"</span><span class="hl-0">: </span><span class="hl-2">"[Shark Clean Account Email]"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"password"</span><span class="hl-0">: </span><span class="hl-2">"[Shark Clean Account Password]"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"oAuthCode"</span><span class="hl-0">: </span><span class="hl-2">"[Optional. Use for manually obtaining credentials]"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"vacuums"</span><span class="hl-0">: [</span><br><span class="hl-0"> </span><span class="hl-2">"[Shark Vacuum DSN]"</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-2">"..."</span><br><span class="hl-0"> ],</span><br><span class="hl-0"> </span><span class="hl-1">"europe"</span><span class="hl-0">: </span><span class="hl-3">false</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"invertDockedStatus"</span><span class="hl-0">: </span><span class="hl-3">false</span><span class="hl-0">,</span><br><span class="hl-0"> </span><span class="hl-1">"dockedUpdateInterval"</span><span class="hl-0">: </span><span class="hl-4">30000</span><br><span class="hl-0"> }</span><br><span class="hl-0"> ]</span><br><span class="hl-0">}</span>
14
+ </code><button type="button">Copy</button></pre>
15
+
16
+ <a id="important" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Important<a href="#important" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h1><p>You may be prompted to use the manual OAuth login method. In order to use the manual OAuth login method, you must remove the email and password values in your configuration first.</p>
17
+ <a id="" class="tsd-anchor"></a><h1 class="tsd-anchor-link"></h1><p>The email and password is your Shark Clean account you used to setup the vacuum. The Vacuums array is a list of your vacuum's device serial numbers (DSN). If you only have one vacuum, just include the one's DSN. The DSN(s) can be found in the SharkClean mobile app.</p>
18
+ <p>If you would like to manually obtain your Shark Clean credentials without using your email and password, you can obtain a OAuth code instead. Refer to the <code>OAuth Code Login Method</code> section.</p>
19
+ <p>The Vacuums array is a list of your vacuum's device serial numbers (DSN). If you only have one vacuum, just include the one's DSN. The DSN(s) can be found in the SharkClean mobile app.</p>
20
+ <p>If you are in Europe, set the <code>europe</code> config value to <code>true</code>. SharkClean has separate servers for the U.S. and Europe. The default value is <code>false</code>, which connects to the U.S. server.</p>
21
+ <p>The default interval between updating the docked status is 30 seconds (30000 ms). To change the docked status interval, add <code>dockedUpdateInterval</code> to your config. Value is in milliseconds. If the interval is too low, you have the risk of your account being rate limited.</p>
22
+ <a id="features" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Features<a href="#features" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2><ul>
23
+ <li>Be able to turn on and off the vacuum</li>
24
+ <li>Set the power mode of the vacuum and change it while running</li>
25
+ <li>Sensor for if the vacuum is docked or not
26
+ <ul>
27
+ <li>The sensor will display as "opened" when the vacuum is docked and "closed" when the vacuum is not docked</li>
28
+ <li>Set <code>invertDockedStatus</code> to <code>true</code> to display as "closed" when the vacuum is docked and "opened" when the vacuum is not docked</li>
29
+ </ul>
30
+ </li>
31
+ <li>Pause switch for pausing the vacuum while it's running</li>
32
+ </ul>
33
+ <a id="oauth-code-login-method" class="tsd-anchor"></a><h3 class="tsd-anchor-link">OAuth Code Login Method<a href="#oauth-code-login-method" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h3><p>The OAuth Code value is for creating and storing the login for the plugin. Here is how to sign in with this method.</p>
34
+ <ol>
35
+ <li>Run Homebridge with the latest plugin version.</li>
36
+ <li>Open the Homebridge logs</li>
37
+ <li>Open the URL in the console printed by homebridge-sharkiq. Safari will not work due to the way Safari handles the results of the login</li>
38
+ <li>Before you login, open up developer tools in your browser (inspect element), and navigate to the network tab</li>
39
+ <li>Enter your login info, and press continue</li>
40
+ <li>Open the request with the uri of <code>/authorize/resume</code> that shows up and view the headers</li>
41
+ <li>Search <code>com.sharkninja.shark</code> in the headers</li>
42
+ <li>Copy the code in between <code>code=</code> and <code>&amp;</code>. for example in <code>com.sharkninja.shark://login.sharkninja.com/ios/com.sharkninja.shark/callback?code=abcdefghijkl&amp;state=</code>, <code>abcdefghijkl</code> is the code that needs to be copied</li>
43
+ <li>Open your Homebridge configuration, and paste the <code>code</code> value in the OAuth Code config option</li>
44
+ <li>Restart Homebridge</li>
45
+ </ol>
46
+ <a id="notes" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Notes<a href="#notes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2><p>Contributions would be very helpful to help this Homebridge plugin stay maintained and up to date. If you have any problems, please create an issue.</p>
47
+ <a id="useful-links" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Useful Links<a href="#useful-links" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2><ul>
48
+ <li><a href="https://github.com/JeffResc/sharkiq/">SharkIQ Python</a></li>
49
+ </ul>
50
+ </div></div><div class="col-sidebar" tabindex="-1"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked=""><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open="" class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>On This Page</h3></summary><div class="tsd-accordion-details" tabindex="-1"><a href="#homebridge-shark-clean-vacuum-plugin"><span>Homebridge <wbr>Shark <wbr>Clean <wbr>Vacuum <wbr>Plugin</span></a><ul><li><a href="#install-and-setup"><span>Install and <wbr>Setup</span></a></li><li><ul><li><a href="#step-1"><span>Step 1.</span></a></li><li><a href="#step-2"><span>Step 2.</span></a></li></ul></li></ul><a href="#important"><span>Important</span></a><a href="#"><span></span></a><ul><li><a href="#features"><span>Features</span></a></li><li><ul><li><a href="#oauth-code-login-method"><span>OAuth <wbr>Code <wbr>Login <wbr>Method</span></a></li></ul></li><li><a href="#notes"><span>Notes</span></a></li><li><a href="#useful-links"><span>Useful <wbr>Links</span></a></li></ul></div></details></div><div class="site-menu" tabindex="-1"><nav class="tsd-navigation"><a href="modules.html">@homebridge-plugins/homebridge-sharkiq</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"></ul></nav></div></div></div></main></body></html>
@@ -0,0 +1,2 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="."><head><style>body { visibility: hidden; }</style><meta charset="utf-8"><meta http-equiv="x-ua-compatible" content="IE=edge"><title>@homebridge-plugins/homebridge-sharkiq</title><meta name="description" content="Documentation for @homebridge-plugins/homebridge-sharkiq"><meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="assets/style.css"><link rel="stylesheet" href="assets/highlight.css"><script defer="" src="assets/main.js"></script><script async="" src="assets/icons.js" id="tsd-icons-script"></script><link rel="stylesheet" href="assets/dmt/dmt-components.css"><link rel="stylesheet" href="assets/dmt/dmt-theme.css"><script src="assets/dmt/dmt-components.js" type="module"></script><noscript><style>body { visibility: visible; }</style></noscript></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";</script><div class="overlay"></div>
2
+ <main><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field" id="dmt-search-main"></div><div class="field" id="dmt-toolbar"><a href="index.html" class="title">@homebridge-plugins/homebridge-sharkiq</a></div></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main" tabindex="-1"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"></ul><div class="dmt-title-header-flex"><h1>@homebridge-plugins/homebridge-sharkiq</h1></div></div><details class="tsd-panel-group tsd-member-group tsd-accordion" open=""><summary class="tsd-accordion-summary" data-key="section-Functions"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg> Functions</h2></summary><dl class="tsd-member-summaries"><dt class="tsd-member-summary"><a id="default" class="tsd-anchor"></a><span class="tsd-member-summary-name"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Function"><use href="assets/icons.svg#icon-64"></use></svg><a href="functions/default.html">default</a><a href="#default" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></span></dt><dd class="tsd-member-summary"></dd></dl></details></div><div class="col-sidebar" tabindex="-1"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked=""><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open="" class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>On This Page</h3></summary><div class="tsd-accordion-details" tabindex="-1"><details open="" class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Functions"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Functions</summary><div><a href="#default" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Function"><use href="assets/icons.svg#icon-64"></use></svg><span>default</span></a></div></details></div></details></div><div class="site-menu" tabindex="-1"><nav class="tsd-navigation"><a href="modules.html" class="current">@homebridge-plugins/homebridge-sharkiq</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"></ul></nav></div></div></div></main></body></html>
@@ -0,0 +1,49 @@
1
+ import antfu from '@antfu/eslint-config'
2
+
3
+ export default antfu(
4
+ {
5
+ ignores: ['dist', 'docs'],
6
+ jsx: false,
7
+ typescript: true,
8
+ formatters: {
9
+ markdown: true,
10
+ },
11
+ rules: {
12
+ 'curly': ['error', 'multi-line'],
13
+ 'import/order': 0,
14
+ 'jsdoc/check-alignment': 'error',
15
+ 'jsdoc/check-line-alignment': 'error',
16
+ 'perfectionist/sort-exports': 'error',
17
+ 'perfectionist/sort-imports': [
18
+ 'error',
19
+ {
20
+ groups: [
21
+ 'builtin-type',
22
+ 'external-type',
23
+ 'internal-type',
24
+ ['parent-type', 'sibling-type', 'index-type'],
25
+ 'builtin',
26
+ 'external',
27
+ 'internal',
28
+ ['parent', 'sibling', 'index'],
29
+ 'object',
30
+ 'unknown',
31
+ ],
32
+ order: 'asc',
33
+ type: 'natural',
34
+ },
35
+ ],
36
+ 'perfectionist/sort-named-exports': 'error',
37
+ 'perfectionist/sort-named-imports': 'error',
38
+ 'sort-imports': 0,
39
+ 'style/brace-style': ['error', '1tbs', { allowSingleLine: true }],
40
+ 'style/quote-props': ['error', 'consistent-as-needed'],
41
+ 'test/no-only-tests': 'error',
42
+ 'unicorn/no-useless-spread': 'error',
43
+ 'unused-imports/no-unused-vars': ['error', { caughtErrors: 'none' }],
44
+ 'no-new': 0, // Disable the no-new rule
45
+ 'new-cap': 0, // Disable the new-cap rule
46
+ 'no-undef': 0, // Disable the no-undef rule
47
+ },
48
+ },
49
+ )
package/package.json ADDED
@@ -0,0 +1,87 @@
1
+ {
2
+ "name": "@homebridge-plugins/homebridge-sharkiq",
3
+ "displayName": "SharkIQ Plugin",
4
+ "type": "module",
5
+ "version": "1.3.2",
6
+ "description": "A Homebridge plugin to connect your Shark Vacuum to homebridge.",
7
+ "author": {
8
+ "name": "Bubba8291",
9
+ "url": "https://github.com/Bubba8291"
10
+ },
11
+ "license": "Apache-2.0",
12
+ "maintainers": [
13
+ "Bubba8291"
14
+ ],
15
+ "funding": {
16
+ "type": "paypal",
17
+ "url": "https://paypal.me/ggg8291"
18
+ },
19
+ "repository": {
20
+ "type": "git",
21
+ "url": "git+https://github.com/homebridge-plugins/homebridge-sharkiq.git"
22
+ },
23
+ "bugs": {
24
+ "url": "https://github.com/homebridge-plugins/homebridge-sharkiq/issues"
25
+ },
26
+ "keywords": [
27
+ "homebridge-plugin",
28
+ "sharkiq"
29
+ ],
30
+ "main": "dist/index.js",
31
+ "engines": {
32
+ "homebridge": "^1.10.0 || ^2.0.0 || ^2.0.0-beta.27",
33
+ "node": "^22 || ^24"
34
+ },
35
+ "scripts": {
36
+ "check": "npm install && npm outdated",
37
+ "lint": "eslint src/**/**.ts --max-warnings=0",
38
+ "lint:fix": "eslint src/**/*.ts --fix",
39
+ "watch": "npm run build && npm run plugin-ui && npm link && nodemon",
40
+ "plugin-ui": "rsync ./src/homebridge-ui/public/index.html ./dist/homebridge-ui/public/",
41
+ "build": "npm run clean && tsc && npm run plugin-ui",
42
+ "prepublishOnly": "npm run lint && npm run build && npm run plugin-ui && npm run docs && npm run docs:lint && npm run docs:theme",
43
+ "postpublish": "npm run clean && npm ci",
44
+ "clean": "shx rm -rf ./dist",
45
+ "test": "npm install",
46
+ "test:watch": "vitest watch",
47
+ "test-coverage": "npm run test -- --coverage",
48
+ "docs": "typedoc",
49
+ "docs:lint": "typedoc --emit none --treatWarningsAsErrors",
50
+ "docs:theme": "typedoc --theme default-modern"
51
+ },
52
+ "publishConfig": {
53
+ "access": "public"
54
+ },
55
+ "dependencies": {
56
+ "@homebridge/plugin-ui-utils": "^2.1.0",
57
+ "node-fetch": "^2.6.1",
58
+ "puppeteer": "^23.3.0",
59
+ "puppeteer-extra": "^3.3.6",
60
+ "puppeteer-extra-plugin-stealth": "^2.11.2"
61
+ },
62
+ "devDependencies": {
63
+ "@antfu/eslint-config": "^4.17.0",
64
+ "@eslint/compat": "^1.3.1",
65
+ "@eslint/eslintrc": "^3.3.1",
66
+ "@types/aes-js": "^3.1.4",
67
+ "@types/debug": "^4.1.12",
68
+ "@types/fs-extra": "^11.0.4",
69
+ "@types/mdast": "^4.0.4",
70
+ "@types/node": "^24.0.14",
71
+ "@types/semver": "^7.7.0",
72
+ "@types/source-map-support": "^0.5.10",
73
+ "@typhonjs-typedoc/typedoc-theme-dmt": "^0.3.1",
74
+ "@vitest/coverage-v8": "^3.2.4",
75
+ "eslint": "^9.31.0",
76
+ "eslint-plugin-format": "^1.0.1",
77
+ "eslint-plugin-import": "^2.32.0",
78
+ "homebridge": "^1.11.0",
79
+ "homebridge-config-ui-x": "5.1.0",
80
+ "nodemon": "^3.1.10",
81
+ "shx": "^0.4.0",
82
+ "ts-node": "^10.9.2",
83
+ "typedoc": "^0.27.6",
84
+ "typescript": "^5.7.3",
85
+ "vitest": "^3.0.7"
86
+ }
87
+ }
package/typedoc.json ADDED
@@ -0,0 +1,21 @@
1
+ {
2
+ "plugin": [
3
+ "@typhonjs-typedoc/typedoc-theme-dmt"
4
+ ],
5
+ "theme": "default-modern",
6
+ "out": "docs",
7
+ "exclude": ["src/**/*.spec.ts"],
8
+ "entryPoints": [
9
+ "src/index.ts"
10
+ ],
11
+ "excludePrivate": true,
12
+ "excludeProtected": true,
13
+ "excludeExternals": true,
14
+ "hideGenerator": true,
15
+ "includeVersion": false,
16
+ "validation": {
17
+ "invalidLink": true,
18
+ "notExported": false
19
+ },
20
+ "inlineTags": ["@link", "@see"]
21
+ }