Clicking Save Chart with the name field empty fired a toast but left the
modal scrolled wherever the user was (e.g. on the chart preview at the
bottom), so they couldn't see what was wrong. Scroll the name field into
view and focus it before delegating to the existing save handler.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The fractional-tick bar/line/area scenario isn't the bug we're shipping in
this PR. Keep only the pie tooltip spacing/formatting change.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Returning [value, name] from the tooltip formatter rendered as two adjacent text nodes ("3Nps"). Return a fragment with an explicit space so it reads "3 Nps".
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
ENG-914
When a chart's measures are all whole numbers (e.g. COUNT grouped by a
dimension), Recharts was auto-generating fractional y-axis ticks like
0.5, 1.5, 2 — nonsensical for a discrete count. The pie tooltip also
rendered values via raw String() with no thousand separators.
- Add allValuesAreIntegers() + formatYAxisTick() to chart-utils.
- CartesianChart now passes allowDecimals={false} and a number-aware
tickFormatter to YAxis when every measure value is an integer.
- ChartRenderer's pie tooltip routes the value through formatCellValue,
matching the Cartesian tooltip behaviour.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Tests now expect validation failures when CUBEJS_API_URL, CUBEJS_API_SECRET,
or HUB_API_KEY are missing, and all test env helpers provide HUB_API_KEY.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Makes Cube env vars mandatory in env.ts (per PR #7913) and adds them
as Docker build secrets with fallback values, following the same pattern
as DATABASE_URL, REDIS_URL, and HUB_API_URL.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
HUB_API_URL is required by the Zod env validation at build time but was
not provided as a Docker secret, causing the release build to fail.
Adds HUB_API_URL with a dummy fallback (http://localhost:4000) to the
build pipeline, following the same pattern as DATABASE_URL/REDIS_URL.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Hub 0.3.0 renames the `user_identifier` API field to `user_id` (breaking
change). This commit bumps the Hub Docker image, upgrades the
@formbricks/hub TypeScript SDK from 0.4.3 to 0.5.0, and renames every
`user_identifier` reference in Zod schemas, server actions, transform
pipeline, form components, CubeJS schema, connector types, and seed data
to match the new API contract.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move duplicated function to @/lib/ai/service and export TAIUnavailableReason
type. Remove local copies from charts-list-page and dashboard-detail-page.
- Server-side: Replace hardcoded OpenAI with provider-agnostic `getAiModel(env)` and enforce
`assertOrganizationAIConfigured(organizationId, "dataAnalysis")` which validates license
entitlement, org-level toggle, and instance configuration
- Client-side: Instead of hiding AI section when unavailable, show it disabled with a tooltip
explaining the reason (not in plan / not enabled / instance not configured), following the
same pattern as AI translate
- Thread `isAIAvailable` and `aiUnavailableReason` through the component chain from server
pages down to `AIQuerySection`
- Update test mocks to match new provider-agnostic AI imports