Keep Tailwind's scan off the server-side folders

The task work added ref strings ([file:ID], [bot:3]) in new prompt and tool
files, so the warning about "file" not being a known CSS property came back:
Tailwind read them as arbitrary-property utilities and emitted `file: ID`.

The exclusion list now covers every server-side directory whole instead of
one file at a time (none of them holds a className, so nothing is lost), and
`dict` stays scanned for the static hue classes. The ref literals that must
live in scanned files are reworded in comments, and task-file-row builds its
chip through `fileRef` rather than its own template literal.
This commit is contained in:
2026-10-22 06:06:25 +01:00
parent 7cb26c4e36
commit 07042a2288
5 changed files with 36 additions and 19 deletions
@@ -8,10 +8,10 @@ import {
const RefPattern = /^\[(bot|workspace):(\d+)\](?!\()/;
/**
* How the composer's mention node reads and writes markdown: a bot as
* `[bot:3]` (`botRef`), a workspace as `[workspace:2]` (`workspaceRef`),
* so a draft or a sent message holds the same refs bots write. A ref
* followed by `(` is a markdown link, not a mention.
* How the composer's mention node reads and writes markdown: a bot ref
* (`botRef`) or a workspace ref (`workspaceRef`), so a draft or a sent
* message holds the same refs bots write. A ref followed by `(` is a
* markdown link, not a mention.
*/
export const MentionMarkdown = {
markdownTokenizer: {
@@ -50,7 +50,7 @@ export const MentionMarkdown = {
};
/**
* The ref a mention writes, `[bot:3]` unless it's a workspace's.
* The ref a mention writes, a bot's unless it's a workspace's.
*/
export function mentionRef({ id, char }: { id?: string | number | null; char?: string | null }) {
const kind = ComposerMentionKinds[(char || "@") as ComposerMentionChar] || "bot";