diff --git a/package-lock.json b/package-lock.json index 12b1403..ff480d6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -22,8 +22,6 @@ "handlebars": "^4.7.8", "html-bundler-webpack-plugin": "^3.13.0", "html-loader": "^5.0.0", - "marked": "^13.0.0", - "marked-alert": "^2.0.1", "postcss-loader": "^8.1.1", "sass": "^1.76.0", "sass-loader": "^14.2.1", @@ -3764,27 +3762,6 @@ "node": ">=10" } }, - "node_modules/marked": { - "version": "13.0.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-13.0.0.tgz", - "integrity": "sha512-VTeDCd9txf4KLLljUZ0nljE/Incb9SrWuueE44QVuU0pkOdh4sfCeW1Z6lPcxyDRSVY6rm8db/0OPaN75RNUmw==", - "dev": true, - "bin": { - "marked": "bin/marked.js" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/marked-alert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/marked-alert/-/marked-alert-2.0.1.tgz", - "integrity": "sha512-dREhBjpPEN87b5AdlpETVoEpYiROQJ2M01sqjvQetKqpfi92BQRfSFKPIEkm90RnMpv5CFLNpWfGO6bx+tnayQ==", - "dev": true, - "peerDependencies": { - "marked": ">=7.0.0" - } - }, "node_modules/marquee-content": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/marquee-content/-/marquee-content-4.2.0.tgz", diff --git a/package.json b/package.json index ec87d05..2539d3f 100644 --- a/package.json +++ b/package.json @@ -27,8 +27,6 @@ "handlebars": "^4.7.8", "html-bundler-webpack-plugin": "^3.13.0", "html-loader": "^5.0.0", - "marked": "^13.0.0", - "marked-alert": "^2.0.1", "postcss-loader": "^8.1.1", "sass": "^1.76.0", "sass-loader": "^14.2.1", diff --git a/src/pages/rooting.md b/src/pages/rooting.md index fdecb24..587ef20 100644 --- a/src/pages/rooting.md +++ b/src/pages/rooting.md @@ -4,45 +4,23 @@ Before rooting your TV, please think about what you would like to do with a rooted TV. -| Use Case | Root Required | -|-------------------------------------------------|---------------| -| Using Kodi | No | -| Stream PC games with Moonlight | No | -| Amblight setup | Yes | -| Remapping remote control buttons | Yes | -| Keeping Kodi's `.kodi` directory on a USB drive | Yes | +| Use Case | Root Required | Dev Mode | +|--------------------------------------------------------------------------------|---------------|----------| +| Use apps like Kodi, Moonlight, etc. | ✅ | ✅ | +| No need for renewing developer mode per 1000 hours | ✅ | ❌ | +| Amblight setup with [PicCap][PicCap]/[Hyperion][Hyperion]/[HyperHDR][HyperHDR] | ✅ | ❌ | +| Change screensaver, wallpaper, etc. | ✅ | ❌ | +| Remapping remote control buttons | ✅ | ❌ | -Use Kodi? That doesn't require root. - -Stream PC games with Moonlight? That doesn't require root either. - -For many uses, like installing some useful homebrew applications, root is **NOT** required. -Using developer mode is enough most of the time and not hard to set up either. -It requires an account though, and you'll have to renew the developer mode every -1000 hours. - -However, an Amblight setup with -[PicCap](https://github.com/TBSniller/piccap)/[Hyperion](https://github.com/webosbrew/hyperion-webos)/[HyperHDR](https://github.com/webosbrew/hyperhdr-webos-loader) -*will* require root. - -Remapping remote control buttons with [lginputhook](https://github.com/Simon34545/lginputhook) requires root. - -Keeping Kodi's `.kodi` directory on a USB drive also requires root. - -> [!NOTE] -> Highlights information that users should take into account, even when skimming. - -> [!TIP] -> Optional information to help a user be more successful. +## Can I root my TV? > [!IMPORTANT] -> Crucial information necessary for users to succeed. - -> [!WARNING] -> Critical content demanding immediate user attention due to potential risks. +> Root exploits are constantly being patched. This table may not be up-to-date. -> [!CAUTION] -> Negative potential consequences of an action. +| webOS version | RootMy.TV | crashd | WTA | DEBUG via NVM | GetMeNow (GetMeIn) | DejaVuln | +|---------------|----------------|----------------|----------------|---------------|--------------------|----------| +| 1.0 - 2.0 | Not compatible | Not compatible | Not compatible | Works | ❌ | ❌ | +| 3.0 - 3.4 | Not compatible | Not compatible | Not compatible | ^ | ❌ | ❌ | ### Benefits of Rooting @@ -59,23 +37,21 @@ Keeping Kodi's `.kodi` directory on a USB drive also requires root. * Rooting is safe, but reckless changes are not - You could brick your TV if you don't have proper knowledge and ignore **[warnings](https://rootmy.tv/warning)** -## How Do I Use Homebrew Apps Without Root? - -Using [dev-manager-desktop](https://github.com/webosbrew/dev-manager-desktop) makes this pretty easy. - -Install from webOS Homebrew repo - -## I Want Root Anyway! - As of February 2024, LG has released multiple patches for the vulnerabilities we found. Depending on the firmware and model, there are multiple approaches to rooting a webOS TV. +- [DejaVuln](https://github.com/throwaway96/dejavuln-autoroot) - For webOS 3.5 and up - [RootMy.TV](https://rootmy.tv/) - For webOS 3.4 and up, but very likely patched (read the [README](https://github.com/RootMyTV/RootMyTV.github.io?tab=readme-ov-file#readme) first!) -- [crashd](https://gist.github.com/throwaway96/e811b0f7cc2a705a5a476a8dfa45e09f) - For webOS 4.0 and up; patches being - rolled out +- [crashd](https://gist.github.com/throwaway96/e811b0f7cc2a705a5a476a8dfa45e09f) - For webOS 4.0 and up; patched - [WTA](https://gist.github.com/throwaway96/b171240ef59d7f5fd6fb48fc6dfd2941) - For webOS 5 and up; patches being rolled out - [DEBUG via NVM](https://gist.github.com/throwaway96/827ff726981cc2cbc46a22a2ad7337a1) - Works on all webOS versions prior to 4.0 (plus NetCast/GP) but requires opening up the TV (no permanent hardware modifications) -- GetMeIn - May work on webOS up to 3.4 on certain models, but don't use the original binary from the XDA thread \ No newline at end of file +- GetMeIn - May work on webOS up to 3.4 on certain models, but don't use the original binary from the XDA thread + +[PicCap]: https://github.com/TBSniller/piccap + +[Hyperion]:https://github.com/webosbrew/hyperion-webos + +[HyperHDR]:https://github.com/webosbrew/hyperhdr-webos-loader \ No newline at end of file diff --git a/src/scss/styles.scss b/src/scss/styles.scss index 3a652e3..334da46 100644 --- a/src/scss/styles.scss +++ b/src/scss/styles.scss @@ -1,5 +1,10 @@ // Include functions first @import "bootstrap/scss/functions"; +@import "bootstrap/scss/variables"; +@import "bootstrap/scss/variables-dark"; +@import "bootstrap/scss/maps"; +@import "bootstrap/scss/mixins"; +@import "bootstrap/scss/utilities"; // Customize some defaults $primary: #cf0652; @@ -8,4 +13,65 @@ $primary: #cf0652; @import "bootstrap"; $bootstrap-icons-font-dir: "~bootstrap-icons/font/fonts"; -@import "~bootstrap-icons/font/bootstrap-icons.scss"; \ No newline at end of file +@import "~bootstrap-icons/font/bootstrap-icons.scss"; + +html { + scroll-padding-top: 65px; +} + +.alert.alert-primary { + --bs-primary-text-emphasis: #{$blue-300}; + --bs-primary-bg-subtle: #{$blue-900}; + --bs-primary-border-subtle: #{$blue-700}; + @extend .alert-primary; +} + +@include color-mode(light) { + .alert.alert-primary { + --bs-primary-text-emphasis: #{$blue-900}; + --bs-primary-bg-subtle: #{$blue-100}; + --bs-primary-border-subtle: #{$blue-200}; + @extend .alert-primary; + } +} + +.callout { + @extend .px-3; + @extend .overflow-hidden; + + @extend .border; + @extend .border-4; + @extend .border-top-0; + @extend .border-bottom-0; + @extend .border-end-0; + + &.callout-danger { + @extend .border-danger; + + .callout-title { + @extend .text-danger; + } + } + + &.callout-warning { + @extend .border-warning; + + .callout-title { + @extend .text-warning; + } + } + + &.callout-important { + border-color: $purple-400 !important; + + .callout-title { + color: $purple-400 !important; + } + } + +} + +.callout-title { + @extend .mt-2; + @extend .fw-bold; +} diff --git a/src/views/develop.hbs b/src/views/develop.hbs new file mode 100644 index 0000000..6f00bf9 --- /dev/null +++ b/src/views/develop.hbs @@ -0,0 +1,7 @@ +{{#*inline "content"}} +

Development

+

+ Under construction. +

+{{/inline}} +{{> page title="Development" }} \ No newline at end of file diff --git a/src/views/devmode.hbs b/src/views/devmode.hbs new file mode 100644 index 0000000..5143a18 --- /dev/null +++ b/src/views/devmode.hbs @@ -0,0 +1,8 @@ +{{#*inline "content"}} +

Dev Mode

+

+ Use officially supported development mode to install homebrew apps and games. +

+ {{> rooted-vs-devmode }} +{{/inline}} +{{> page title="Dev Mode" }} \ No newline at end of file diff --git a/src/views/index/index.scss b/src/views/index/index.scss index d99e222..1915d4d 100644 --- a/src/views/index/index.scss +++ b/src/views/index/index.scss @@ -1,10 +1,6 @@ @import "../../scss/styles"; @import "bootstrap/scss/variables"; -html { - scroll-padding-top: 65px; -} - .tv-container { position: relative; diff --git a/src/views/partials/footer.html b/src/views/partials/footer.html index 226846f..ed652f3 100644 --- a/src/views/partials/footer.html +++ b/src/views/partials/footer.html @@ -7,8 +7,8 @@
Guides
diff --git a/src/views/page/page.hbs b/src/views/partials/page.hbs similarity index 75% rename from src/views/page/page.hbs rename to src/views/partials/page.hbs index da46b40..da2bec3 100644 --- a/src/views/page/page.hbs +++ b/src/views/partials/page.hbs @@ -4,16 +4,19 @@ {{title}} | webOS Homebrew - + {{> navbar }}
- {{markdown (include page)}} + {{> content}}
{{> footer }} +{{#script}} + +{{/script}} diff --git a/src/views/partials/rooted-vs-devmode.html b/src/views/partials/rooted-vs-devmode.html new file mode 100644 index 0000000..3955b75 --- /dev/null +++ b/src/views/partials/rooted-vs-devmode.html @@ -0,0 +1,47 @@ +

Rooted vs Dev Mode

+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Use CaseRootedDev Mode
Use apps like Kodi, Moonlight, etc.
Manage apps with Dev Manager
No need for renewing developer mode per 1000 hours
Ambient light setup with PicCap/Hyperion/HyperHDR
Change screensaver, wallpaper, etc.
Remapping remote control buttons
+
\ No newline at end of file diff --git a/src/views/rooting.hbs b/src/views/rooting.hbs new file mode 100644 index 0000000..68e24ab --- /dev/null +++ b/src/views/rooting.hbs @@ -0,0 +1,135 @@ +{{#*inline "content"}} + +

Rooting

+

+ Decide whether to root your device. +

+ {{> rooted-vs-devmode }} +
+

Can I root my TV?

+
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
webOS versionRootMy.TVcrashdWTAGetMeNowDejaVulnNVM
1.x
Not supported

Not supported

Not supported
🩹
Patched

Not supported

Supported
2.x
3.0~3.4🪦
Patched, very unlikely to work

Not supported
3.5~
Being patched
4.x🪦
Patched, very unlikely to work

Not supported
5.x🩹
Patched
6.x
7.x
Not supported
8.x
9.x~Not rootable (yet)
+
+
+
+

Rooting methods

+
+ +

RootMy.TV

+

+ Patched in mid-2022. +

+

crashd

+

+ Patched in April 2024. +

+

WTA

+

+ Patched in recent updates. +

+

GetMeNow

+

+ Works on some models running webOS 1.x and 2.x. +

+

DejaVuln

+

+ Works on webOS 3.5 and up. Patches are being rolled out, starting from recent models. +

+

NVM

+ +

+ Alternatively, DEBUG flag can be modified via hardware modification to gain + root access for pre-webOS 4.0 models. +

+
+{{/inline}} +{{> page title="Rooting" }} \ No newline at end of file diff --git a/webpack.config.js b/webpack.config.js index ca5046d..0e140a3 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -3,9 +3,6 @@ const path = require('path'); const HtmlBundlerPlugin = require('html-bundler-webpack-plugin'); const {FaviconsBundlerPlugin} = require('html-bundler-webpack-plugin/plugins'); -const {SafeString} = require('handlebars'); -const marked = require('marked'); -const markedAlert = require("marked-alert"); module.exports = { mode: 'development', @@ -21,21 +18,17 @@ module.exports = { import: './src/views/index/index.hbs', }, rooting: { - import: './src/views/page/page.hbs', + import: './src/views/rooting.hbs', filename: 'rooting/index.html', - data: { - title: 'Rooting', - page: 'src/pages/rooting.md' - } }, devmode: { - import: './src/views/page/page.hbs', + import: './src/views/devmode.hbs', filename: 'devmode/index.html', - data: { - title: 'Developer Mode', - page: 'src/pages/devmode.md' - } - } + }, + develop: { + import: './src/views/develop.hbs', + filename: 'develop/index.html', + }, }, preprocessor: 'handlebars', preprocessorOptions: { @@ -43,24 +36,13 @@ module.exports = { partials: [ 'src/views/partials' ], - helpers: { - 'markdown': (string) => { - let html = marked.use(markedAlert({ - className: 'alert', - })).parse(typeof string === 'string' ? string : string.string, { - async: false, - gfm: true, - breaks: false, - }); - return new SafeString(html); - }, - } }, loaderOptions: { sources: [{ tag: 'span', attributes: ['data-img-src', 'data-amblight-src'] }] }, + hotUpdate: true, js: { // JS output filename, used if `inline` option is false (defaults) filename: 'js/[name].[contenthash:8].js', @@ -100,6 +82,7 @@ module.exports = { resolve: { alias: { '@img': path.resolve(__dirname, 'src/img'), + '@styles': path.resolve(__dirname, 'src/scss'), } } }