Skip to content

[DATABRICKS-5] PLU-600: add frontend support for databricks dynamic actions#1530

Open
pregnantboy wants to merge 1 commit intodatabricks/4-create-rowfrom
databricks/5-frontend
Open

[DATABRICKS-5] PLU-600: add frontend support for databricks dynamic actions#1530
pregnantboy wants to merge 1 commit intodatabricks/4-create-rowfrom
databricks/5-frontend

Conversation

@pregnantboy
Copy link
Copy Markdown
Contributor

@pregnantboy pregnantboy commented Apr 7, 2026

Add dynamic action support and validation for dropdown options

Add dynamic action GraphQL mutation for creating Databricks tables and columns. Refactor AddNewOptionModal to use configuration-driven approach with validation support for different dropdown types. Implement inline validation for SingleSelect components and update collaborator permission checks to use addNewId-based restrictions instead of field-based ones.

  • Add DYNAMIC_ACTION GraphQL mutation for handling dynamic dropdown actions
  • Refactor AddNewOptionModal to use ADD_NEW_OPTION_CONFIGS with validation functions
  • Add validation for Databricks table/column names (lowercase letters, numbers, underscores only)
  • Support inline validation in SingleSelect with error display
  • Add cases for databricks-createTable and databricks-createTableColumn in create new option flow
  • Update collaborator restrictions to check COLLABORATOR_RESTRICTED_ADDNEW_IDS instead of field labels
  • Add form error handling and helper text display in modal

Copy link
Copy Markdown
Contributor Author

pregnantboy commented Apr 7, 2026

@pregnantboy pregnantboy changed the title feat: add frontend support for databricks dynamic actions [DATABRICKS-5] PLU-600: add frontend support for databricks dynamic actions Apr 7, 2026
@linear
Copy link
Copy Markdown

linear bot commented Apr 7, 2026

@pregnantboy pregnantboy marked this pull request as ready for review April 7, 2026 07:01
@pregnantboy pregnantboy requested a review from a team as a code owner April 7, 2026 07:01
@datadog-opengovsg
Copy link
Copy Markdown

datadog-opengovsg bot commented Apr 7, 2026

✅ Tests

🎉 All green!

❄️ No new flaky tests detected
🧪 All tests passed

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 4e8abbc | Docs | Was this helpful? Give us feedback!

@pregnantboy pregnantboy force-pushed the databricks/5-frontend branch from 8cac423 to dae7518 Compare April 7, 2026 09:43
@pregnantboy pregnantboy force-pushed the databricks/4-create-row branch 2 times, most recently from 189d3bc to f94b3fa Compare April 7, 2026 09:51
@pregnantboy pregnantboy force-pushed the databricks/5-frontend branch 2 times, most recently from 382be49 to 735d13a Compare April 13, 2026 03:08
@pregnantboy pregnantboy force-pushed the databricks/4-create-row branch from f94b3fa to 6ee411e Compare April 13, 2026 03:08
@pregnantboy pregnantboy force-pushed the databricks/5-frontend branch from 735d13a to 4440c19 Compare April 13, 2026 03:30
@pregnantboy pregnantboy force-pushed the databricks/4-create-row branch from 6ee411e to 41da125 Compare April 13, 2026 03:30
Copy link
Copy Markdown
Contributor

@kevinkim-ogp kevinkim-ogp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

two small nits, other than that lgtm tested and works 🧱

Comment thread packages/frontend/src/components/ControlledAutocomplete/AddNewOptionModal.tsx Outdated
Comment thread packages/frontend/src/components/ControlledAutocomplete/AddNewOptionModal.tsx Outdated
@pregnantboy pregnantboy force-pushed the databricks/4-create-row branch from 41da125 to a3de2ea Compare April 16, 2026 08:44
@pregnantboy pregnantboy force-pushed the databricks/5-frontend branch from 4440c19 to 14cd673 Compare April 16, 2026 08:44
Comment on lines +52 to +54
if (!/^[a-zA-Z0-9_]+$/.test(value)) {
return 'Only alphanumeric characters and underscores are allowed'
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Validation regex doesn't match user-facing description. The regex /^[a-zA-Z0-9_]+$/ allows both uppercase AND lowercase letters, but line 81 tells users "Only lowercase letters, numbers and underscores allowed."

// Current regex allows uppercase:
if (!/^[a-zA-Z0-9_]+$/.test(value)) {

// Should be lowercase only:
if (!/^[a-z0-9_]+$/.test(value)) {

Users will successfully create tables with uppercase letters, which may fail in Databricks if it requires lowercase names.

Spotted by Graphite

Fix in Graphite


Is this helpful? React 👍 or 👎 to let us know.

Add dynamic action GraphQL mutation, refactor AddNewOptionModal to be
config-driven with validation support, add databricks create-table and
create-column cases, support inline validation on SingleSelect, and
update collaborator restrictions to use addNewId-based checks.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@pregnantboy pregnantboy force-pushed the databricks/4-create-row branch from a3de2ea to 775b175 Compare April 17, 2026 06:32
@pregnantboy pregnantboy force-pushed the databricks/5-frontend branch from 14cd673 to 4e8abbc Compare April 17, 2026 06:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants