Skip to content

feat: add support muxing rules #311

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 32 commits into from
Feb 14, 2025
Merged
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
2e79fcc
chore: add dnd-kit, uuid and upgrade ui-kit
peppescg Feb 12, 2025
c7ff57d
feat: create SortableArea generic component
peppescg Feb 12, 2025
b439c97
feat: replacing zustand store with useFormState, rename filename
peppescg Feb 12, 2025
883e76a
feat: replace drag icon
peppescg Feb 12, 2025
6f313bd
feat: add models dropdown
peppescg Feb 12, 2025
980d590
feat: create a remove queries utility fn
peppescg Feb 13, 2025
0ae1d16
refactor: simplify logic for handling dirty and reset form state
peppescg Feb 13, 2025
71203ab
feat: update muxing rules
peppescg Feb 13, 2025
0bad848
feat: show remove button if multiple rules
peppescg Feb 13, 2025
51ee877
feat: add link to doc and manager providers link
peppescg Feb 13, 2025
5d76949
refactor: remove unneeded div wrapper
peppescg Feb 13, 2025
e3c64fe
feat: use form buttons
peppescg Feb 13, 2025
90c399c
leftover
peppescg Feb 13, 2025
9f4e2a0
feat: change notfication message
peppescg Feb 13, 2025
9c53ff9
chore: update msw handlers
peppescg Feb 13, 2025
3580f94
fix: update rules and add tests case
peppescg Feb 13, 2025
56e0e24
refactor: rename filename
peppescg Feb 13, 2025
54db8f4
refactor: revert changes
peppescg Feb 13, 2025
33a93f6
chore: update openapi
peppescg Feb 13, 2025
6a3551d
fix: matcher_type for filename
peppescg Feb 13, 2025
02dbfad
feat: set the default muxing rule as catch all
peppescg Feb 13, 2025
6dd61e6
fix: update workspace name and models
peppescg Feb 13, 2025
1e3bf2a
test: update muxing model
peppescg Feb 13, 2025
7d86f5a
fix: type
peppescg Feb 13, 2025
97b7c33
fix: drag sortable area
peppescg Feb 13, 2025
d9ba640
fix: catch all rule spacing
peppescg Feb 13, 2025
c155d3d
fix: fields alignment
peppescg Feb 14, 2025
62ba893
fix: models unique identifier
peppescg Feb 14, 2025
ff2c857
fix: invalidate models
peppescg Feb 14, 2025
ac1361a
test: update muxing logic
peppescg Feb 14, 2025
1604e40
prettier
peppescg Feb 14, 2025
7b0e5f6
refactor: review
peppescg Feb 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions icons/drag.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
73 changes: 73 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -21,6 +21,8 @@
"generate-icons": "npx @svgr/cli --typescript --no-dimensions --replace-attr-values '#2E323A=currentColor' --jsx-runtime automatic --out-dir ./src/components/icons/ -- icons"
},
"dependencies": {
"@dnd-kit/core": "^6.3.1",
"@dnd-kit/sortable": "^10.0.0",
"@hey-api/client-fetch": "^0.7.1",
"@jsonforms/core": "^3.5.1",
"@jsonforms/react": "^3.5.1",
@@ -52,6 +54,7 @@
"tailwind-variants": "^0.3.1",
"tailwindcss-animate": "^1.0.7",
"ts-pattern": "^5.6.2",
"uuid": "^11.0.5",
"zod": "^3.24.1"
},
"devDependencies": {
19 changes: 13 additions & 6 deletions src/api/generated/types.gen.ts
Original file line number Diff line number Diff line change
@@ -35,11 +35,11 @@ export type Alert = {
| {
[key: string]: unknown
}
| null
trigger_type: string
trigger_category: string | null
timestamp: string
}
| null;
trigger_type: string;
trigger_category: AlertSeverity;
timestamp: string;
};

/**
* Represents an alert with it's respective conversation.
@@ -59,6 +59,11 @@ export type AlertConversation = {
timestamp: string
}

export enum AlertSeverity {
INFO = "info",
CRITICAL = "critical",
}

/**
* Represents a chat message.
*/
@@ -140,7 +145,9 @@ export type ModelByProvider = {
* Represents the different types of matchers we support.
*/
export enum MuxMatcherType {
CATCH_ALL = 'catch_all',
CATCH_ALL = "catch_all",
FILENAME_MATCH = "filename_match",
REQUEST_TYPE_MATCH = "request_type_match",
}

/**
Loading
Loading