Skip to content

Commit

Permalink
docs: improve node documentations (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
clement-berard authored Nov 29, 2024
1 parent 2027d38 commit fccf4b5
Show file tree
Hide file tree
Showing 8 changed files with 1,354 additions and 45 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@
"@release-it/conventional-changelog": "9.0.3",
"@types/jquery": "3.5.32",
"@types/jqueryui": "1.12.23",
"@types/node": "^22.10.0",
"@types/node": "^22.10.1",
"@types/node-red": "1.3.5",
"release-it": "17.10.0",
"tsx": "4.19.2",
"typescript": "^5.6.3"
},
"dependencies": {
"@keload/node-red-dxp": "^1.10.2",
"@keload/node-red-dxp": "^1.11.0",
"philtv-js": "^1.7.1",
"superstruct": "2.0.2"
},
Expand Down
1,322 changes: 1,301 additions & 21 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

14 changes: 0 additions & 14 deletions src/nodes/ambilight/doc.md

This file was deleted.

23 changes: 23 additions & 0 deletions src/nodes/ambilight/docs.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import {assumedValues} from './node-config'

Manage Ambilight brightness and modes.

_If payload is passed, it will set values passed in the payload.
All other values configured in the node will be ignored._

Valid `msg.payload`:

{Object.entries(assumedValues).map(([key, value]) => (
<pre key={key}>
<code>
{JSON.stringify(
{
action: key,
value: value.join(' | '),
},
null,
2
)}
</code>
</pre>
))}
4 changes: 0 additions & 4 deletions src/nodes/info/doc.md

This file was deleted.

14 changes: 14 additions & 0 deletions src/nodes/info/docs.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import nodeConfig from './node-config'

Get TV information System, Ambilight current information and TV structure.

_If payload is passed, it will set values passed in the payload.
All other values configured in the node will be ignored._

Valid `msg.payload`:

<ul>
{nodeConfig.getAvailableKinds().map(val => (
<li key={val}><code>{val}</code></li>
))}
</ul>
4 changes: 0 additions & 4 deletions src/nodes/send-key/doc.md

This file was deleted.

14 changes: 14 additions & 0 deletions src/nodes/send-key/docs.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import {inputKeys} from './node-config'

Send key to your TV (Play, Pause, Volume Up, Volume Down, etc.)

_If payload is passed, it will set values passed in the payload.
All other values configured in the node will be ignored._

Valid `msg.payload`:

<ul>
{inputKeys.map(val => (
<li key={val}><code>{val}</code></li>
))}
</ul>

0 comments on commit fccf4b5

Please sign in to comment.