refactor(ui): replace inline INPUT_CLS/BTN_DANGER/action link constants with component classes
- Replace 13 local INPUT_CLS/SELECT_CLS/LABEL_CLS/BTN_DANGER constants with app-input, app-select, app-label, app-action-danger-btn component classes (CustomFieldFilterBar, RolePresetsEditor, FieldCard, BlueprintFieldCatalog, BlueprintFieldEditor, BlueprintsClient, EstimateWizard, EstimateWorkspace- DraftEditor, DemandLineEditor, ScopeItemEditor, AssumptionEditor, ProjectWizard, BulkEditModal) - Replace inline text-blue-600/text-red-500 action link strings with app-action-edit / app-action-delete in AllocationsClient, ProjectsClient, ScenarioPlanner, ProjectDemandsTable, RolesClient, BlueprintsClient, CreateTaskModal, RateCardsClient, UsersClient, ManagementLevelsClient Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -166,7 +166,7 @@ export function ProjectDemandsTable({ demands, project }: ProjectDemandsTablePro
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setEditTarget(demand as unknown as AllocationWithDetails)}
|
||||
className="text-xs font-medium text-blue-600 hover:text-blue-800 dark:text-blue-400 dark:hover:text-blue-200"
|
||||
className="app-action-edit"
|
||||
>
|
||||
Edit
|
||||
</button>
|
||||
|
||||
@@ -30,13 +30,9 @@ const ALLOCATION_TYPE_OPTIONS = [
|
||||
{ value: "EXT", label: "EXT" },
|
||||
] as const;
|
||||
|
||||
const INPUT_CLS =
|
||||
"px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-brand-500 text-sm w-full";
|
||||
|
||||
const SELECT_CLS =
|
||||
"px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-brand-500 text-sm w-full bg-white";
|
||||
|
||||
const LABEL_CLS = "block text-xs font-medium text-gray-600 mb-1";
|
||||
const INPUT_CLS = "app-input";
|
||||
const SELECT_CLS = "app-select w-full";
|
||||
const LABEL_CLS = "app-label";
|
||||
|
||||
const BTN_PRIMARY =
|
||||
"px-5 py-2 bg-brand-600 text-white rounded-lg hover:bg-brand-700 text-sm font-medium disabled:opacity-50 transition-colors";
|
||||
@@ -44,8 +40,7 @@ const BTN_PRIMARY =
|
||||
const BTN_SECONDARY =
|
||||
"px-5 py-2 border border-gray-300 text-gray-700 rounded-lg hover:bg-gray-50 text-sm font-medium transition-colors";
|
||||
|
||||
const BTN_DANGER =
|
||||
"px-2 py-1 text-red-500 hover:text-red-700 hover:bg-red-50 rounded text-sm transition-colors";
|
||||
const BTN_DANGER = "app-action-danger-btn";
|
||||
|
||||
// ─── Types ────────────────────────────────────────────────────────────────────
|
||||
|
||||
|
||||
@@ -501,7 +501,7 @@ function ScenarioRowEditor({
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => onRestore(row.key)}
|
||||
className="text-xs text-blue-600 hover:text-blue-800 underline"
|
||||
className="app-action-edit"
|
||||
>
|
||||
Restore
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user