diff --git a/plugins/leetcode-summary/README.md b/plugins/leetcode-summary/README.md index 3c8a310b..737de2a1 100644 --- a/plugins/leetcode-summary/README.md +++ b/plugins/leetcode-summary/README.md @@ -1,10 +1,15 @@ # LeetCode Summary -A community `topbarGlyph` plugin for Ryoku Linux. It puts a small `LC` glyph on -the bar; click it for a panel with your LeetCode solved counts, global rank, -difficulty split, streak, acceptance rate and a 12-week activity map. The -username is a setting that starts empty, so **each installer sees their own summary** — type a -username into the panel and press Enter to switch instantly. +A community plugin for Ryoku Linux with **one shared data source and two hosts**: +a small `LC` glyph on the bar with a click-through panel, and a matching +paper-and-ink tile on the desktop. Both show your LeetCode solved counts, global +rank, difficulty split, streak, acceptance, language mix and a 12-week activity +map. The username is a setting, so **each installer sees their own summary** — +type a username into the panel and press Enter to switch instantly. + +This replaces the separate LeetCode Pulse desktop plugin: the bar glyph and the +desktop tile are two views of the same plugin, like Coffee and VPN do, so there +is only one helper and one settings block to maintain. It uses the same public [alfa-leetcode-api](https://github.com/alfaarghya/alfa-leetcode-api) as the author's portfolio (`alfa-leetcode-api.onrender.com`). No token, login or @@ -13,18 +18,27 @@ API key is needed. ## Files - `service/Main.qml`: polls the helper every `pollSeconds` (default 600s, range - 120–3600), keeps the last good snapshot and exposes it to both views. -- `content/Widget.qml`: the bar glyph. Shows the solved count when `showCount` - is on and a tooltip with the handle, rank and streak. -- `content/Panel.qml`: the click-through summary with the editable username field. -- `bin/leetcode_summary.py`: fetches `/profile`, `/solved` and `/calendar` in - parallel, computes the compact figures and caches a good snapshot. + 120–3600), keeps the last good snapshot and exposes it to both views. An empty + username is a no-op, so a fresh install never shows someone else's profile. +- `content/Widget.qml`: the view both hosts mount; dispatches on density to + `Glyph.qml` at `glyph` and `Card.qml` at `compact`. +- `content/Glyph.qml`: the bar glyph. Shows the solved count when `showCount` + is on and a tooltip with the handle, rank, streak and acceptance rate. +- `content/Card.qml`: the desktop tile with the same stats, a difficulty bar, + a 12-column activity grid (one column per week, today outlined), accepted / + submission totals, an optional solved-progress track and the top languages. + A click opens your profile; hovering highlights the card. The status pill + distinguishes `SET USERNAME`, `IDLE`, `SYNCING`, `SAVED` and `LIVE`. +- `content/Panel.qml`: the click-through summary with the editable username field + and accepted / submission totals. +- `bin/leetcode_summary.py`: fetches `/profile`, `/solved`, `/calendar` and + `/language` in parallel, computes the compact figures and caches a good snapshot. ## Settings | key | type | default | description | | ----------- | ------ | --------- | ------------------------------------ | -| username | text | (empty) | LeetCode handle shown in the panel | +| username | text | (empty) | LeetCode handle; set it in the panel | | pollSeconds | int | 600 | Refresh interval, 120–3600 seconds | | showCount | toggle | true | Show the solved count next to `LC` | @@ -38,13 +52,19 @@ also be changed under **QS Bar Settings > Community > LeetCode Summary**. - The username is URL-encoded as one path component and never passed to a shell. - Writes only `summary.json` under `pluginApi.stateDir`. A partial API outage never overwrites a good cache, and a cache is only read for the username it - belongs to. Offline, the panel shows the saved snapshot with `SAVED.`. + belongs to. Offline, both views show the saved snapshot with `SAVED.`. - No credentials, no privileged commands, no binary blobs. ## Preview +Bar glyph / panel: + ![LeetCode Summary panel](assets/preview-widget.png) +Desktop tile: + +![LeetCode Summary desktop tile](assets/preview-desktop.png) + ## Build, check, install ``` @@ -52,7 +72,10 @@ ryoku plugin validate . ryoku plugin add . --bar --yes ``` -Enable it under **QS Bar Settings > Community**. +Then enable the desktop tile too under **QS Bar Settings > Community > +LeetCode Summary**, and place it with `ryoku-plugins-place leetcode-summary +desktopWidget ` if it does not appear. Both views share +the same username and polling settings. ## Author diff --git a/plugins/leetcode-summary/assets/preview-desktop.png b/plugins/leetcode-summary/assets/preview-desktop.png new file mode 100644 index 00000000..e13c65ff Binary files /dev/null and b/plugins/leetcode-summary/assets/preview-desktop.png differ diff --git a/plugins/leetcode-summary/bin/leetcode_summary.py b/plugins/leetcode-summary/bin/leetcode_summary.py index 4643d515..f7b4e4d5 100644 --- a/plugins/leetcode-summary/bin/leetcode_summary.py +++ b/plugins/leetcode-summary/bin/leetcode_summary.py @@ -13,7 +13,7 @@ import urllib.request BASE = "https://alfa-leetcode-api.onrender.com" -PATHS = ("/profile", "/solved", "/calendar") +PATHS = ("/profile", "/solved", "/calendar", "/language") def fetch(username, path): @@ -54,7 +54,7 @@ def build_dots(raw_calendar): try: # Calendar keys are Unix timestamps in seconds, not day counts. day = dt.datetime.fromtimestamp(int(key), dt.timezone.utc).date() - counts[day.isoformat()] = min(int(value), 3) + counts[day.isoformat()] = min(int(value), 5) except (TypeError, ValueError, OSError, OverflowError): continue today = dt.datetime.now(dt.timezone.utc).date() @@ -62,14 +62,11 @@ def build_dots(raw_calendar): def main(): - username = sys.argv[1].strip() if len(sys.argv) > 1 else "" - if not username: - print("usage: leetcode_summary.py ", file=sys.stderr) - sys.exit(2) + username = sys.argv[1] if len(sys.argv) > 1 else "" state_dir = sys.argv[2] if len(sys.argv) > 2 else "" cache_path = os.path.join(state_dir, "summary.json") if state_dir else "" - with concurrent.futures.ThreadPoolExecutor(max_workers=3) as pool: + with concurrent.futures.ThreadPoolExecutor(max_workers=4) as pool: futures = [(path, pool.submit(fetch, username, path)) for path in PATHS] results = {} for path, future in futures: @@ -103,11 +100,18 @@ def load_cached(): profile = results.get("/profile") or {} solved = results.get("/solved") or {} calendar = results.get("/calendar") or {} + languages = results.get("/language") or {} total_attempts = bucket(solved.get("totalSubmissionNum"), "All").get("submissions", 0) or 0 total_accepted = bucket(solved.get("acSubmissionNum"), "All").get("submissions", 0) or 0 acceptance = round(total_accepted / total_attempts * 100) if total_attempts else 0 + langs = [ + {"name": row.get("languageName", ""), "count": row.get("problemsSolved", 0)} + for row in (languages.get("languageProblemCount") or []) + ] + langs.sort(key=lambda row: row["count"], reverse=True) + data = { "username": username, "solved": solved.get("solvedProblem", profile.get("totalSolved", 0)) or 0, @@ -120,6 +124,9 @@ def load_cached(): "streak": calendar.get("streak", 0) or 0, "activeDays": calendar.get("totalActiveDays", 0) or 0, "acceptance": acceptance, + "accepted": total_accepted, + "submissions": total_attempts, + "languages": langs[:3], "dots": build_dots(calendar.get("submissionCalendar", "{}")), "fetchedAt": int(dt.datetime.now(dt.timezone.utc).timestamp()), "live": live, diff --git a/plugins/leetcode-summary/content/Card.qml b/plugins/leetcode-summary/content/Card.qml new file mode 100644 index 00000000..e2816ec6 --- /dev/null +++ b/plugins/leetcode-summary/content/Card.qml @@ -0,0 +1,329 @@ +pragma ComponentBehavior: Bound + +import QtQuick +import Ryoku.PluginKit.Singletons + +// LeetCode Summary — the desktopWidget host's compact stats tile. The bar host +// mounts Glyph.qml instead; both share the same service and settings. All +// colour, type and geometry come from the plugin kit; the only data colour is +// the accent ramp on the difficulty bar and the activity dots. +Item { + id: root + + property var pluginApi + property var screen + property bool active: false + property string density: "compact" + property real s: 1 + property real widthBudget: 0 + property bool open: false + property real reveal: 0 + property bool tabActive: false + signal requestClose() + + readonly property var service: pluginApi ? pluginApi.mainInstance : null + readonly property var stats: service && service.stats ? service.stats : ({}) + readonly property var dots: root.stats.dots ? root.stats.dots : [] + + function num(value) { return value ? Number(value) : 0; } + function rankText(value) { + var n = num(value); + if (n >= 1000000) return (n / 1000000).toFixed(2) + "M"; + if (n >= 1000) return (n / 1000).toFixed(1) + "k"; + return String(n); + } + + readonly property int solved: num(root.stats.solved) + readonly property int easy: num(root.stats.easy) + readonly property int medium: num(root.stats.medium) + readonly property int hard: num(root.stats.hard) + readonly property int streak: num(root.stats.streak) + readonly property int acceptance: num(root.stats.acceptance) + readonly property int activeDays: num(root.stats.activeDays) + readonly property int accepted: num(root.stats.accepted) + readonly property int submissions: num(root.stats.submissions) + readonly property string username: root.stats.username ? root.stats.username : "" + + implicitWidth: 320 * root.s + implicitHeight: 226 * root.s + + Rectangle { + anchors.fill: parent + color: Theme.cardTop + border.color: tileMouse.containsMouse ? Theme.accent : Theme.hair + border.width: 1 + radius: Theme.radius + } + + // Inverted header band — the one high-contrast surface on the tile. + Rectangle { + id: header + anchors.top: parent.top + anchors.left: parent.left + anchors.right: parent.right + height: 34 * root.s + color: Theme.accent + radius: Theme.radius + } + + Text { + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + anchors.verticalCenter: header.verticalCenter + text: "LEETCODE / @" + (root.username || "SET USERNAME") + color: Theme.cardBot + font.family: Theme.mono + font.pixelSize: 11 * root.s + font.letterSpacing: 1.2 * root.s + } + + Text { + anchors.right: parent.right + anchors.rightMargin: 14 * root.s + anchors.verticalCenter: header.verticalCenter + text: !root.username ? "SET USERNAME" + : (service && service.loading) ? "SYNCING" + : (service && service.errorText) ? "SAVED" + : (Object.keys(root.stats).length > 0) ? "LIVE" : "IDLE" + color: Theme.cardBot + font.family: Theme.mono + font.pixelSize: 9 * root.s + font.letterSpacing: 1 * root.s + opacity: 0.8 + } + + // Headline metric. + Text { + id: solvedNumber + anchors.top: header.bottom + anchors.topMargin: 14 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + text: String(root.solved) + color: Theme.bright + font.family: Theme.display + font.pixelSize: 54 * root.s + font.bold: true + lineHeight: 0.85 + } + + Text { + anchors.left: solvedNumber.right + anchors.leftMargin: 10 * root.s + anchors.bottom: solvedNumber.bottom + anchors.bottomMargin: 7 * root.s + text: "PROBLEMS\nSOLVED" + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 9 * root.s + lineHeight: 1.35 + } + + Text { + id: rankLine + anchors.top: solvedNumber.bottom + anchors.topMargin: 3 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + text: "GLOBAL RANK " + root.rankText(root.stats.rank) + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 9 * root.s + } + + // Optional progress track: solved against the platform's question total. + Rectangle { + anchors.left: rankLine.right + anchors.leftMargin: 10 * root.s + anchors.verticalCenter: rankLine.verticalCenter + visible: num(root.stats.total) > 0 + width: 70 * root.s + height: 4 * root.s + radius: Theme.radius + color: Theme.hair + Rectangle { + width: Math.min(parent.width, parent.width * root.solved / Math.max(1, num(root.stats.total))) + height: parent.height + radius: Theme.radius + color: Theme.accent + } + } + + // Difficulty split — a single hairline bar with three accent tints. + Row { + id: splitBar + anchors.top: solvedNumber.bottom + anchors.topMargin: 15 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + width: 190 * root.s + height: 7 * root.s + spacing: 1 * root.s + + Rectangle { + width: root.solved > 0 ? (parent.width * root.easy / root.solved) : 0 + height: parent.height + color: Qt.lighter(Theme.accent, 1.55) + } + Rectangle { + width: root.solved > 0 ? (parent.width * root.medium / root.solved) : 0 + height: parent.height + color: Qt.lighter(Theme.accent, 1.22) + } + Rectangle { + width: root.solved > 0 ? (parent.width * root.hard / root.solved) : 0 + height: parent.height + color: Theme.accent + } + } + + Row { + anchors.top: splitBar.bottom + anchors.topMargin: 7 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + spacing: 12 * root.s + + Text { + text: "E " + root.easy + " M " + root.medium + " H " + root.hard + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 9 * root.s + } + } + + // Two secondary metrics, separated by a hairline rule. + Rectangle { + id: rule + anchors.top: splitBar.bottom + anchors.topMargin: 26 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + width: 190 * root.s + height: 1 + color: Theme.hair + } + + Text { + anchors.top: rule.bottom + anchors.topMargin: 9 * root.s + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + text: root.streak + " DAY STREAK" + color: Theme.bright + font.family: Theme.font + font.pixelSize: 12 * root.s + font.bold: true + } + + Text { + anchors.top: rule.bottom + anchors.topMargin: 10 * root.s + anchors.left: parent.left + anchors.leftMargin: 118 * root.s + text: root.acceptance + "% ACCEPT" + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 9 * root.s + } + + Text { + anchors.top: rule.bottom + anchors.topMargin: 22 * root.s + anchors.left: parent.left + anchors.leftMargin: 118 * root.s + text: root.accepted + "/" + root.submissions + " ACCEPTED" + color: Theme.faint + font.family: Theme.mono + font.pixelSize: 8 * root.s + } + + // Twelve weeks of activity, seven days per column. + Text { + id: dotsLabel + anchors.top: header.bottom + anchors.topMargin: 16 * root.s + anchors.right: parent.right + anchors.rightMargin: 14 * root.s + text: "12W ACTIVITY" + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 8 * root.s + font.letterSpacing: 1 * root.s + } + + Grid { + id: dotGrid + anchors.top: dotsLabel.bottom + anchors.topMargin: 8 * root.s + anchors.right: parent.right + anchors.rightMargin: 14 * root.s + columns: 12 + spacing: 3 * root.s + + Repeater { + model: root.dots + delegate: Rectangle { + required property var modelData + required property int index + property int level: modelData ? Number(modelData) : 0 + width: 4 * root.s + height: 4 * root.s + radius: Theme.radius + border.width: index === root.dots.length - 1 ? 1 : 0 + border.color: Theme.accent + color: level === 0 + ? Theme.hair + : Qt.rgba(Theme.accent.r, Theme.accent.g, Theme.accent.b, 0.18 + 0.82 * level / 5) + } + } + } + + // Footer: language mix and the live/saved source line. + Rectangle { + anchors.left: parent.left + anchors.right: parent.right + anchors.bottom: parent.bottom + height: 1 + color: Theme.hair + } + + Text { + anchors.left: parent.left + anchors.leftMargin: 14 * root.s + anchors.bottom: parent.bottom + anchors.bottomMargin: 10 * root.s + text: { + if (!root.username) return "SET A USERNAME IN THE BAR PANEL"; + var langs = root.stats.languages ? root.stats.languages : []; + if (!langs.length) return service && service.loading ? "Fetching languages…" : "No language data"; + return langs.map(function (item) { return item.name + " " + item.count; }).join(" · "); + } + color: Theme.dim + font.family: Theme.mono + font.pixelSize: 9 * root.s + elide: Text.ElideRight + width: 230 * root.s + } + + Text { + anchors.right: parent.right + anchors.rightMargin: 14 * root.s + anchors.bottom: parent.bottom + anchors.bottomMargin: 10 * root.s + text: service && service.errorText ? service.errorText : (root.activeDays + " ACTIVE DAYS") + color: Theme.faint + font.family: Theme.mono + font.pixelSize: 8 * root.s + } + + MouseArea { + id: tileMouse + anchors.fill: parent + hoverEnabled: true + onClicked: { + if (root.username) + Qt.openUrlExternally("https://leetcode.com/u/" + encodeURIComponent(root.username) + "/"); + } + } +} diff --git a/plugins/leetcode-summary/content/Glyph.qml b/plugins/leetcode-summary/content/Glyph.qml new file mode 100644 index 00000000..01c282a0 --- /dev/null +++ b/plugins/leetcode-summary/content/Glyph.qml @@ -0,0 +1,73 @@ +pragma ComponentBehavior: Bound + +import QtQuick +import QtQuick.Controls +import Ryoku.PluginKit.Singletons + +// The bar host's view: a small LeetCode monogram plus the solved count. Clicking +// toggles the summary panel; a tooltip carries the key numbers. The desktop +// host mounts Card.qml instead; both read the same service instance. +Item { + id: root + + property var pluginApi + property var screen + property bool active: false + property string density: "glyph" + property real s: 1 + property real widthBudget: 220 + property bool open: false + property real reveal: 0 + property bool tabActive: false + signal requestClose() + + readonly property var service: pluginApi ? pluginApi.mainInstance : null + readonly property var stats: service && service.stats ? service.stats : ({}) + readonly property int solved: stats.solved || 0 + readonly property int streak: stats.streak || 0 + + implicitWidth: Math.max(22 * root.s, row.implicitWidth) + implicitHeight: 24 * root.s + + Row { + id: row + anchors.verticalCenter: parent.verticalCenter + spacing: 5 * root.s + + Text { + anchors.verticalCenter: parent.verticalCenter + text: "LC" + color: (root.active || root.open || hover.containsMouse) ? Theme.accent : Theme.bright + font.family: "JetBrainsMono Nerd Font Mono" + font.pixelSize: 11 * root.s + font.bold: true + } + + Text { + anchors.verticalCenter: parent.verticalCenter + visible: !!service && !!service.showCount + text: root.solved + color: Theme.dim + font.family: "JetBrainsMono Nerd Font Mono" + font.pixelSize: 11 * root.s + } + } + + MouseArea { + id: hover + anchors.fill: parent + hoverEnabled: true + onClicked: { + if (root.pluginApi && root.pluginApi.togglePanel) + root.pluginApi.togglePanel(); + } + ToolTip.visible: containsMouse + ToolTip.text: stats.username + ? "@" + stats.username + " · " + root.solved + " solved · " + + (stats.rankText || "-") + " rank · " + root.streak + "d streak" + + " · " + (stats.acceptance || 0) + "% accept" + : "LeetCode Summary" + ToolTip.delay: 450 + ToolTip.timeout: 3000 + } +} diff --git a/plugins/leetcode-summary/content/Panel.qml b/plugins/leetcode-summary/content/Panel.qml index 2b5ee8b7..fa4ae195 100644 --- a/plugins/leetcode-summary/content/Panel.qml +++ b/plugins/leetcode-summary/content/Panel.qml @@ -135,6 +135,13 @@ Item { font.pixelSize: 10 * root.s font.letterSpacing: 1.2 } + + Text { + text: (root.stats.accepted || 0) + " accepted / " + (root.stats.submissions || 0) + " submissions" + color: Theme.faint + font.family: Theme.font + font.pixelSize: 9 * root.s + } } Row { diff --git a/plugins/leetcode-summary/content/Widget.qml b/plugins/leetcode-summary/content/Widget.qml index e5fbbda5..fee0654f 100644 --- a/plugins/leetcode-summary/content/Widget.qml +++ b/plugins/leetcode-summary/content/Widget.qml @@ -1,14 +1,14 @@ pragma ComponentBehavior: Bound import QtQuick -import QtQuick.Controls -import Ryoku.PluginKit.Singletons -// The single view the bar mounts: a small LeetCode monogram plus the solved -// count. Clicking toggles the summary panel; a tooltip carries the key numbers. +// Both hosts mount this one view. It dispatches on density: the bar glyph at +// "glyph" and the desktop stats tile otherwise. All state comes from the same +// service (pluginApi.mainInstance); a click on the bar only toggles the panel. Item { id: root + // Host-set; read only, never assign. property var pluginApi property var screen property bool active: false @@ -20,52 +20,34 @@ Item { property bool tabActive: false signal requestClose() - readonly property var service: pluginApi ? pluginApi.mainInstance : null - readonly property var stats: service && service.stats ? service.stats : ({}) - readonly property int solved: stats.solved || 0 - readonly property int streak: stats.streak || 0 - - implicitWidth: Math.max(22 * root.s, row.implicitWidth) - implicitHeight: 24 * root.s - - Row { - id: row - anchors.verticalCenter: parent.verticalCenter - spacing: 5 * root.s - - Text { - anchors.verticalCenter: parent.verticalCenter - text: "LC" - color: (root.active || root.open || hover.containsMouse) ? Theme.accent : Theme.bright - font.family: "JetBrainsMono Nerd Font Mono" - font.pixelSize: 11 * root.s - font.bold: true - } - - Text { - anchors.verticalCenter: parent.verticalCenter - visible: !!service && !!service.showCount - text: root.solved - color: Theme.dim - font.family: "JetBrainsMono Nerd Font Mono" - font.pixelSize: 11 * root.s + readonly property bool isGlyph: density === "glyph" + readonly property var view: isGlyph ? glyphLoader.item : cardLoader.item + + implicitWidth: view ? view.implicitWidth : 22 * root.s + implicitHeight: view ? view.implicitHeight : 24 * root.s + + Loader { + id: glyphLoader + active: root.isGlyph + sourceComponent: Glyph { + pluginApi: root.pluginApi + active: root.active + open: root.open + density: root.density + s: root.s + widthBudget: root.widthBudget } } - MouseArea { - id: hover - anchors.fill: parent - hoverEnabled: true - onClicked: { - if (root.pluginApi && root.pluginApi.togglePanel) - root.pluginApi.togglePanel(); + Loader { + id: cardLoader + active: !root.isGlyph + sourceComponent: Card { + pluginApi: root.pluginApi + active: root.active + density: root.density + s: root.s + widthBudget: root.widthBudget } - ToolTip.visible: containsMouse - ToolTip.text: stats.username - ? "@" + stats.username + " · " + root.solved + " solved · " - + (stats.rankText || "-") + " rank · " + root.streak + "d streak" - : (service && service.username ? "LeetCode Summary" : "LeetCode Summary · set your username") - ToolTip.delay: 450 - ToolTip.timeout: 3000 } } diff --git a/plugins/leetcode-summary/manifest.json b/plugins/leetcode-summary/manifest.json index a35cbd02..3c34f8c0 100644 --- a/plugins/leetcode-summary/manifest.json +++ b/plugins/leetcode-summary/manifest.json @@ -2,13 +2,14 @@ "schema": 1, "id": "leetcode-summary", "name": "LeetCode Summary", - "description": "A bar glyph with a click-through panel showing your LeetCode solved counts, rank, streak, acceptance and 12-week activity, powered by alfa-leetcode-api.", - "version": "0.1.0", + "description": "A bar glyph and a matching desktop tile showing your LeetCode solved counts, rank, difficulty split, streak, acceptance, languages and 12-week activity, powered by alfa-leetcode-api.", + "version": "0.2.0", "license": "MIT", "official": false, "author": "Manish <159711477+mannish01@users.noreply.github.com>", "hosts": [ - "topbarGlyph" + "topbarGlyph", + "desktopWidget" ], "entryPoints": { "main": "service/Main.qml", @@ -30,7 +31,13 @@ }, "defaults": { "host": "topbarGlyph", - "label": "LeetCode Summary" + "label": "LeetCode Summary", + "desktopWidget": { + "x": 1320, + "y": 130, + "scale": 1, + "locked": false + } }, "dependencies": { "commands": [ @@ -39,7 +46,10 @@ }, "files": [ "bin/leetcode_summary.py", - "assets/preview-widget.png" + "content/Glyph.qml", + "content/Card.qml", + "assets/preview-widget.png", + "assets/preview-desktop.png" ], "metadata": { "settings": [ diff --git a/plugins/leetcode-summary/product-manifest.json b/plugins/leetcode-summary/product-manifest.json index 8dadb320..198b0db5 100644 --- a/plugins/leetcode-summary/product-manifest.json +++ b/plugins/leetcode-summary/product-manifest.json @@ -2,7 +2,7 @@ "schema": 1, "id": "leetcode-summary", "category": "plugins", - "version": "0.1.0", + "version": "0.2.0", "destination": "ryoku/plugins/leetcode-summary", "files": [ { @@ -24,9 +24,17 @@ { "source": "README.md", "destination": "README.md", - "sha256": "b624c9986fa17506a245a299eaf1921ed90d04f68d8bdf202f06d759f9fc4b88", + "sha256": "2a2faf141e68b4d5264a9bce441f56115e6646ca03aa126ce5b3cb16a9bad458", "mode": "0644", - "size": 2502, + "size": 3772, + "install": false + }, + { + "source": "assets/preview-desktop.png", + "destination": "assets/preview-desktop.png", + "sha256": "8ac97773ee60aba3b96f78bd6fa078a8ba406eefec90984c82a5c58ad745e2e5", + "mode": "0644", + "size": 45629, "install": false }, { @@ -40,33 +48,49 @@ { "source": "bin/leetcode_summary.py", "destination": "bin/leetcode_summary.py", - "sha256": "cb0bfd81fe6b91d6bf9e6d3f0547abab105988ebb2d7e54bb2ae1e834433e703", + "sha256": "ef960e5524bc769c9cd1158d2b843789046cdf1dcbd91ba1948950cfd8b6a587", + "mode": "0644", + "size": 5353, + "install": true + }, + { + "source": "content/Card.qml", + "destination": "content/Card.qml", + "sha256": "e1b1eb1fd231c23c951f0452641e8d0d22a717f320c5fa20f1d568c90068fbff", + "mode": "0644", + "size": 10484, + "install": true + }, + { + "source": "content/Glyph.qml", + "destination": "content/Glyph.qml", + "sha256": "1cffe9dbf0c0568a471f8312dc3f730314b72fda0b1a26c4571fec0dd3b769e2", "mode": "0644", - "size": 5089, + "size": 2377, "install": true }, { "source": "content/Panel.qml", "destination": "content/Panel.qml", - "sha256": "3a966eb6a6e7bb42e3e8a66d13b27abf718b2aaaab505d1f406cd509c7d19029", + "sha256": "a1f45d7626d39e8708af44d7c5e4a1206b39ab9fc851766b67cc5d41ecf05f72", "mode": "0644", - "size": 13507, + "size": 13774, "install": true }, { "source": "content/Widget.qml", "destination": "content/Widget.qml", - "sha256": "e2bd30e4d11616d329bde2279290d7a22beb082fd0c403ce618664be17d7d987", + "sha256": "117df909043155e7cb6f86603b572da81d25084e1356bc188df28a6b55a3dd10", "mode": "0644", - "size": 2318, + "size": 1498, "install": true }, { "source": "manifest.json", "destination": "manifest.json", - "sha256": "839e452d45378ee06a396caf3714698bb1daab4854cb72796e1985e1c96cf0a8", + "sha256": "9a8bc519a2ed36e8c391c7537dceaaa41cdab0f7c25c3291eb87253596a80c84", "mode": "0644", - "size": 1622, + "size": 1859, "install": true }, { diff --git a/plugins/registry.json b/plugins/registry.json index 7f918c38..8152cf8f 100644 --- a/plugins/registry.json +++ b/plugins/registry.json @@ -4,15 +4,16 @@ { "id": "leetcode-summary", "name": "LeetCode Summary", - "version": "0.1.0", + "version": "0.2.0", "path": "plugins/leetcode-summary", "author": "Manish <159711477+mannish01@users.noreply.github.com>", "upstream": "https://github.com/mannish01/LeetCode-Summary", - "summary": "A bar glyph with a click-through panel showing your LeetCode solved counts, rank, streak, acceptance and 12-week activity.", - "description": "A community topbarGlyph plugin backed by the public alfa-leetcode-api used in the author's portfolio. Type any LeetCode username in the panel and press Enter to see that profile's solved counts, global rank, easy/medium/hard split, streak, acceptance rate and 12-week activity grid. Complete snapshots are cached under the plugin state directory for offline fallback; a partial API outage never overwrites a good cache.", + "summary": "A bar glyph and a matching desktop tile showing your LeetCode solved counts, rank, difficulty split, streak, acceptance, languages and 12-week activity.", + "description": "A community plugin backed by the public alfa-leetcode-api used in the author's portfolio, with one shared helper and two hosts: a bar glyph with a click-through panel and a compact desktop tile. Type any LeetCode username in the panel and press Enter to see that profile's solved counts, global rank, easy/medium/hard split, streak, acceptance rate, language mix and 12-week activity grid in both views. Complete snapshots are cached under the plugin state directory for offline fallback; a partial API outage never overwrites a good cache.", "license": "MIT", "tags": [ "bar-widget", + "desktop-widget", "leetcode", "statistics", "developer" @@ -21,15 +22,17 @@ "surface": "#101010", "preview": "assets/preview-widget.png", "screenshots": [ - "assets/preview-widget.png" + "assets/preview-widget.png", + "assets/preview-desktop.png" ], "manifest": "product-manifest.json", - "manifestSha256": "86e5f6542aac02d91ff62a7344ceb4ce8f72a858877b3071ef20f26807cf8f93", + "manifestSha256": "166448825cb2c915cc7e5751e0389925c5eb289d36381aa4c99a38526b1fed63", "official": false, - "tagline": "Your LeetCode summary, one click from the bar.", + "tagline": "Your LeetCode summary, on the bar and desktop.", "icon": "", "hosts": [ - "topbarGlyph" + "topbarGlyph", + "desktopWidget" ], "lastUpdated": "2026-11-30" },