Skip to content

Workflow canvas dot grid renders above nodes, configuration panels, and menus in Dify 1.17.0 #41451

Open

Description

@sevketpolan

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report, otherwise it will be closed.
  • 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.17

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • This is only for a bug report. If I would like to ask a question, I will use Discussions.
  • I have searched for existing issues, including closed ones.
  • I confirm that I am using English to submit this report.
  • I have not modified the required sections of the bug report template.

Dify version

1.17.0

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

  1. Upgrade an existing self-hosted Dify installation from 1.14.x to 1.17.0.
  2. Use langgenius/dify-web:1.17.0 and langgenius/dify-api:1.17.0.
  3. Open Studio and create or open a Workflow application.
  4. Select an LLM node so that the node configuration panel opens on the right.
  5. Open the variable inspector panel at the bottom.
  6. Observe the workflow canvas dot-grid background across the page.

Deployment details:

  • Deployment: Docker Compose through aaPanel
  • Reverse proxy: aaPanel/Nginx
  • Dify UI language: Turkish
  • Theme: Light
  • Client OS: macOS
  • Browser and version: Google Chrome 151.0.7922.174

✔️ Expected Behavior

✔️ Expected Behavior

The dotted workflow background should be rendered only inside the canvas and behind workflow nodes. Node cards, the right-side configuration panel, the bottom variable inspector, toolbars, menus, and other overlay surfaces should have their normal opaque backgrounds and remain clearly readable.

❌ Actual Behavior

Actual Behavior

The canvas dot grid is rendered above or through nearly every surface in the Studio editor. The dots cover workflow nodes, the LLM configuration panel on the right, the variable inspector at the bottom, toolbars, and menu areas.

This makes the entire editor difficult to read and suggests that the React Flow background/SVG is in an incorrect stacking context or that panel backgrounds are unexpectedly transparent. The issue is visible immediately after opening the workflow editor.

The left Studio navigation sidebar is not affected, while the canvas area and the panels layered over it are affected.

Screenshot

Please drag and drop Screenshot 2026-08-28 at 16.12.04.png here before submitting the issue.

Additional context

The deployment was upgraded from Dify 1.14.x to 1.17.0 while preserving the existing database and storage volumes. Both the API and web services are configured to use the 1.17.0 image tag.

Relevant frontend feature flags in this deployment:

NEXT_PUBLIC_ENABLE_AGENT_V2=true
NEXT_PUBLIC_ENABLE_FEATURE_PREVIEW=true
EXPERIMENTAL_ENABLE_VINEXT=false

No similar issue describing the workflow dot grid rendering over all Studio panels was found in the current 1.17.0 feedback milestone.

Image

Activity

  1. dosubot commented on Aug 28, 2026

    @dosubot

    @sevketpolan thanks for the detailed report and screenshot. I wasn't able to find another open issue or a merged fix specifically matching "dot grid rendered above every panel" in 1.17.0, but I traced the relevant stacking-context code and can share what's likely happening.

    How the layering works today:

    The canvas background is a React Flow <Background> element rendered inside the #workflow-container div, which applies relative isolate to create a scoped stacking context [1]. The background itself uses bg-workflow-canvas-workflow-bg and var(--color-workflow-canvas-workflow-dot-color) for its paint [2].

    The isolate class was introduced in PR #38796 (merged 2026-07-12), which also replaced the old per-container z-index constants (ITERATION_NODE_Z_INDEX, LOOP_NODE_Z_INDEX, LOOP_CHILDREN_Z_INDEX) with a single NESTED_ELEMENT_Z_INDEX = 1001, relying on React Flow's own selected-node elevation of 1000 [3].

    The right-side node configuration panel is an absolutely positioned sibling inside #workflow-container with z-10 [4]. The variable inspector panel is similarly rendered as a sibling with its own opaque background [5].

    What's likely going wrong:

    Given this structure, if the dot-grid is rendering above those panels, the most plausible explanations are:

    1. Stale cached assets from the upgrade — Since you upgraded from 1.14.x → 1.17.0, the browser may be serving a stale JS/CSS bundle where the old z-index values or missing isolate context cause the background's SVG to paint above panel siblings. Try a hard refresh (Cmd+Shift+R) or open in an incognito window to rule this out.

    2. A CSS token resolution issue — If --color-workflow-canvas-workflow-dot-color or the bg-workflow-canvas-workflow-bg class fails to resolve in your environment (e.g., a Tailwind purge or theme mismatch), the background element could end up unstyled in a way that makes it paint at an unexpected layer.

    3. A stacking-context interaction introduced by the z-index normalization PR that manifests only when both the node panel and the variable inspector are open simultaneously (matching your repro steps).

    Suggested next steps to narrow it down:

    • Does this reproduce in an incognito/private browsing session (ruling out stale cache)?
    • Does it reproduce with only the node panel open (without the variable inspector), or only when both are open together?
    • Have you tried docker compose pull && docker compose up -d to ensure no image layer caching from the upgrade?

    That information would help determine whether this is a browser-side cache issue from the upgrade or a genuine stacking-context regression that needs a fix.

    To reply, just mention @dosu.


    Docs are dead. Just use Dosu.

    Leave Feedback Ask Dosu about dify

  2. PiedPiper911 commented on Aug 29, 2026

    @PiedPiper911

    Following up on Dosu's analysis — I traced the stacking-context change in more detail and the regression source is almost certainly PR #38796 ("normalize z-index layering", merged 2026-07-12, 38 files).

    Key mechanism:

    1. #workflow-container now gets relative isolate (workflow/index.tsx:652-660). isolate creates a new stacking context, which is correct for the canvas — but it means everything inside (including the React Flow Background SVG and the absolute panels) is stacked within that context.

    2. The panels (node config, variable inspector) are absolute z-10 siblings inside the container. React Flow's Background is rendered inside the ReactFlow component, which wraps nodes/edges with z-index on .react-flow__renderer — the Background sits below nodes but the panel z-10 competes with React Flow's internal stacking.

    3. Before refactor(web): normalize z-index layering #38796, per-container z-index constants (ITERATION_NODE_Z_INDEX etc.) explicitly ordered nested elements. After the PR, they were replaced with NESTED_ELEMENT_Z_INDEX = 1001 + reliance on React Flow's selected-node elevation (1000). If any code path still assumes the old per-container context, the Background SVG can escape its intended layer.

    What would confirm it: the repro needs both the node panel AND variable inspector open — exactly the state where the old z-index constants would have created distinct stacking groups that the normalized version collapses. Dosu's cache hypothesis doesn't explain why only some surfaces (not the left nav) are affected.

    I can take this one — plan: diff #38796's changes to workflow/index.tsx + panel/index.tsx + variable-inspect/index.tsx, pin down which class/context change lets the Background paint above the panels, and add a regression check. I'd verify against the 1.17.0 web bundle. Happy to open a PR once I've reproduced it locally (or if a maintainer can confirm the repro on their side, that unblocks me faster).

  3. QianJinGuo commented on Aug 29, 2026

    @QianJinGuo
    Contributor

    Thanks @sevketpolan for the detailed report.

    I reproduced the environment on a clean dify-web:1.17.0 + dify-api:1.17.0 docker-compose deployment and dug into this. I'd like to propose a different root cause: this is very likely not a stacking/z-index regression from #38796 (a candidate suspected earlier in this thread), but the design-token layer failing to resolve at runtime (missing html[data-theme], or stale/mixed CSS after the 1.14 → 1.17 upgrade). Full evidence chain below — and I'm happy to take the issue from here (see the end).

    1. The dot grid cannot paint above the panels — verified structurally and at runtime

    • The React Flow Background SVG carries no z-index at all: its inline style is exactly position: absolute; width: 100%; height: 100%; top: 0; left: 0 (@reactflow/background@11.3.14, pinned via reactflow 11.11.4 in both 1.14.0 and 1.17.0), and neither reactflow's stylesheet nor Dify's assigns it one.
    • It mounts as a direct child of .react-flow, which has an inline position: relative; z-index: 0; overflow: hidden (the wrapperStyle in @reactflow/core). That is a stacking context capping the entire canvas subtree below every z-10 sibling inside #workflow-container: the right node panel (absolute top-14 right-0 bottom-1 z-10, web/app/components/workflow/panel/index.tsx), the header (absolute top-7 … z-10), and the variable inspector.
    • Context menus are portalled to <body> with z-50 (packages/dify-ui/src/context-menu/index.tsx), so they are out of reach too. The isolate added by refactor(web): normalize z-index layering #38796 is only a redundant extra cap on the same container.
    • Runtime probes on the healthy 1.17.0 in the exact reported state (node panel and variable inspector open): .react-flow__background computed z-index: auto, .react-flow inline z-index: 0, right panel computed z-index: 10, and elementFromPoint inside the inspector returns the inspector's content — never the SVG. Identical in light and dark themes.

    2. Removing data-theme reproduces this issue's screenshot exactly

    Dify's served CSS ships every design token twice: as a self-referencing placeholder in @layer theme (--color-components-panel-bg: var(--color-components-panel-bg), emitted from the @theme inline mapping in packages/dify-ui/src/themes/theme.css) and as real values in the base layer under html[data-theme='light'] / html[data-theme='dark'] (light.css / dark.css). With data-theme set, the base declaration wins and everything resolves. When the attribute is missing, the cyclic placeholder is the winning declaration — every mapped token becomes invalid at computed-value time at once:

    • all panel/canvas backgrounds collapse to rgba(0, 0, 0, 0) (transparent);
    • the dots' SVG fill falls back to rgb(0, 0, 0) (invalid var() → initial value = black).

    On a light-theme browser that is a white page with black dots showing through the header, right panel, variable inspector and toolbars — visually matching the reported screenshot, including the small black box near the zoom controls (an unstyled overlay) and a clean left sidebar (it sits outside the workflow container; its own token styling degrades too, but white-on-white makes that invisible in light theme).

    Measured values in the same editor state, healthy vs stripped (full probe data recorded as JSON):

    Probe Healthy light data-theme removed
    variable inspector background rgb(255,255,255) rgba(0,0,0,0)
    canvas SVG background rgb(242,244,247) rgba(0,0,0,0)
    dot fill (computed on <circle>) rgba(133,133,173,0.15) rgb(0,0,0)
    z-indexes (SVG / .react-flow / panel) auto / 0 / 10 unchanged auto / 0 / 10

    Note the z-indexes do not change in the broken state — nothing moves between layers; the dots only appear to be "above" because every surface turned transparent.

    SSR ships <html> without data-theme; next-themes sets it via an inline bootstrap script (web/app/layout.tsx). If that script is blocked (a CSP/nonce mismatch introduced by a reverse proxy is a classic cause with aaPanel/Nginx setups), or the CSS/JS chunks are a stale mix cached from the pre-upgrade deployment, you get exactly this rendering.

    3. One-pass diagnostics for @sevketpolan

    1. DevTools → Elements while the issue is visible: does <html> have data-theme="light"?
    2. DevTools → Console/Network: any blocked inline script (CSP) or failing/cached CSS request? Please try a hard refresh / incognito window and purge the aaPanel Nginx cache.
    3. Does it persist after a clean reload? If data-theme is present, assets are intact, and the issue still reproduces, please attach a HAR + the computed styles and I'll keep digging.

    4. Taking this forward

    I'd be glad to take this issue and see it through to a resolution. Concretely:

    • If the diagnostics confirm token loss, I'll prepare a hardening PR — e.g., rendering a server-side default data-theme="light" on <html> in web/app/layout.tsx, so a blocked theme script can never blank out the whole token layer — pending a maintainer's confirmation on the approach.
    • If the reporter's environment turns out to have intact tokens and the issue still reproduces, I'll continue the investigation from a HAR / computed-style dump rather than guessing.

    I'll keep following this thread either way — happy to adjust the direction if a maintainer prefers something different.

    Screenshots

    Same editor state, three conditions:

    1. Healthy, light theme — panels opaque, dots faint and strictly behind panels.
    2. data-theme removed, dark-ambient browser — the same token failure renders as a dark canvas with white text, because next-themes leaves color-scheme: dark inline on <html> even after the theme attribute is gone.
    3. data-theme removed, light theme — the reporter-equivalent rendering: white page, black dots showing through every surface.
    Image Image Image
  4. added
    1.17.0
    on Sep 3, 2026
  5. added this to the 1.17.1 milestone on Sep 3, 2026
  6. added
    🐞 bug
    and removed on Sep 4, 2026
  7. sevketpolan commented on Sep 17, 2026

    @sevketpolan
    Author

    Hi @QianJinGuo

    dify.har.zip

    I've gone through the diagnostic steps and checked the status:

    1. attribute check: When the page is loaded, the data-theme="light" attribute is present and correct.
    2. Console & Network check: Hard refresh and incognito window tests were performed, and the aaPanel Nginx cache was completely purged. Despite this, there are no CSP (Content Security Policy) blocks or failing/cached CSS requests.

    Conclusion: The issue persists even after a clean reload.

    To help you investigate further, I am attaching the HAR file along with the relevant network logs and computed styles. Thanks in advance for taking a look!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    1.17.0🐞 bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions