update: unify
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
|
|
||||||
|
import { Plus, Search } from "lucide-react";
|
||||||
import { ApiRequestError, type Employee, type Workspace, type WorkspaceMember } from "../../services/api";
|
import { ApiRequestError, type Employee, type Workspace, type WorkspaceMember } from "../../services/api";
|
||||||
import { useApi, useAuth } from "../../context/AuthContext";
|
import { useApi, useAuth } from "../../context/AuthContext";
|
||||||
import Icon from "../../components/common/Icon";
|
|
||||||
import { Button } from "~/components/ui/button";
|
import { Button } from "~/components/ui/button";
|
||||||
import {
|
import {
|
||||||
Table,
|
Table,
|
||||||
@@ -244,7 +244,7 @@ export function ProjectManagementPage({
|
|||||||
<section className="admin-page">
|
<section className="admin-page">
|
||||||
<div className="admin-toolbar">
|
<div className="admin-toolbar">
|
||||||
<div className="admin-toolbar__search">
|
<div className="admin-toolbar__search">
|
||||||
<Icon name="search" size={14} />
|
<Search size={14} />
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="请输入项目名称"
|
placeholder="请输入项目名称"
|
||||||
@@ -261,7 +261,7 @@ export function ProjectManagementPage({
|
|||||||
onClick={openCreateProject}
|
onClick={openCreateProject}
|
||||||
className={PRIMARY_BUTTON_CLASS}
|
className={PRIMARY_BUTTON_CLASS}
|
||||||
>
|
>
|
||||||
<Icon name="plus" size={15} />
|
<Plus size={15} />
|
||||||
新建项目
|
新建项目
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -24,6 +24,9 @@ import { AdminColgroup, ROLE_COL_WIDTHS } from "./AdminTable";
|
|||||||
|
|
||||||
import "../../styles/admin.css";
|
import "../../styles/admin.css";
|
||||||
|
|
||||||
|
const PRIMARY_BUTTON_CLASS =
|
||||||
|
"h-[37px] gap-[7px] rounded-md border border-[#126ac3] bg-gradient-to-br from-[#1881e7] to-[#1268c9] px-[15px] text-xs font-[650] text-white shadow-[0_6px_15px_rgb(20_111_202/18%)] enabled:hover:from-[#1175d8] enabled:hover:to-[#0e5bad]";
|
||||||
|
|
||||||
export function RoleManagementPage({
|
export function RoleManagementPage({
|
||||||
onNotify,
|
onNotify,
|
||||||
onConnectionChange,
|
onConnectionChange,
|
||||||
@@ -177,7 +180,7 @@ export function RoleManagementPage({
|
|||||||
<section className="admin-page">
|
<section className="admin-page">
|
||||||
<div className="admin-toolbar">
|
<div className="admin-toolbar">
|
||||||
<div className="admin-toolbar__search">
|
<div className="admin-toolbar__search">
|
||||||
<Search size={14} className="text-[#8a99a8]" />
|
<Search size={14} />
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="搜索角色编码 / 名称"
|
placeholder="搜索角色编码 / 名称"
|
||||||
@@ -192,7 +195,7 @@ export function RoleManagementPage({
|
|||||||
type="button"
|
type="button"
|
||||||
disabled={!canManage}
|
disabled={!canManage}
|
||||||
onClick={openCreate}
|
onClick={openCreate}
|
||||||
className="h-9 gap-1.5 rounded-[6px] bg-gradient-to-br from-[#2e86de] to-[#1978d4] px-3.5 text-[12px] font-semibold text-white shadow-[0_4px_12px_rgb(28_119_222/18%)] enabled:hover:from-[#1f7ed8] enabled:hover:to-[#1669c0]"
|
className={PRIMARY_BUTTON_CLASS}
|
||||||
>
|
>
|
||||||
<Plus size={15} />
|
<Plus size={15} />
|
||||||
新建角色
|
新建角色
|
||||||
|
|||||||
@@ -1,9 +1,8 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
|
|
||||||
import { X } from "lucide-react";
|
import { Plus, Search, X } from "lucide-react";
|
||||||
import { ApiRequestError, type Employee, type Role } from "../../services/api";
|
import { ApiRequestError, type Employee, type Role } from "../../services/api";
|
||||||
import { useApi, useAuth } from "../../context/AuthContext";
|
import { useApi, useAuth } from "../../context/AuthContext";
|
||||||
import Icon from "../../components/common/Icon";
|
|
||||||
import { Button } from "~/components/ui/button";
|
import { Button } from "~/components/ui/button";
|
||||||
import { Input } from "~/components/ui/input";
|
import { Input } from "~/components/ui/input";
|
||||||
import {
|
import {
|
||||||
@@ -198,7 +197,7 @@ export function UserManagementPage({
|
|||||||
<section className="admin-page">
|
<section className="admin-page">
|
||||||
<div className="admin-toolbar">
|
<div className="admin-toolbar">
|
||||||
<div className="admin-toolbar__search">
|
<div className="admin-toolbar__search">
|
||||||
<Icon name="search" size={14} />
|
<Search size={14} />
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="请输入用户名"
|
placeholder="请输入用户名"
|
||||||
@@ -215,7 +214,7 @@ export function UserManagementPage({
|
|||||||
onClick={openCreate}
|
onClick={openCreate}
|
||||||
className={PRIMARY_BUTTON_CLASS}
|
className={PRIMARY_BUTTON_CLASS}
|
||||||
>
|
>
|
||||||
<Icon name="plus" size={15} />
|
<Plus size={15} />
|
||||||
新建用户
|
新建用户
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user