Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
Instance/Data Source detail style tweak
天舟8265f8a34ea2
diff --git a/frontend/src/components/DataSourceMemberTable.vue b/frontend/src/components/DataSourceMemberTable.vueindex d870fae1df..d7da4204f4 100644--- a/frontend/src/components/DataSourceMemberTable.vue+++ b/frontend/src/components/DataSourceMemberTable.vue@@ -1,67 +1,77 @@<template>- <h2 class="text-xl leading-7 font-bold text-main">User list</h2>- <BBTable- class="mt-2"- :columnList="columnList"- :dataSource="memberList"- :showHeader="true"- :rowClickable="false"- >- <template v-slot:header>- <BBTableHeaderCell- :leftPadding="4"- class="w-auto table-cell"- :title="columnList[0].title"- />- <BBTableHeaderCell class="w-8 table-cell" :title="columnList[1].title" />- <BBTableHeaderCell class="w-8 table-cell" :title="columnList[2].title" />- <BBTableHeaderCell- v-if="allowEdit"- class="w-8 table-cell"- :title="columnList[3].title"- />- </template>- <template v-slot:body="{ rowData: member }">- <BBTableCell :leftPadding="4" class="table-cell">- <div class="flex flex-row items-center space-x-2">- <BBAvatar :username="member.principal.name" />- <div class="flex flex-col">- <div class="flex flex-row items-center space-x-2">- <router-link :to="`/u/${member.principal.id}`" class="normal-link"- >{{ member.principal.name }}- </router-link>- <span- v-if="currentUser.id == member.principal.id"- class="inline-flex items-center px-2 py-0.5 rounded-lg text-xs font-semibold bg-green-100 text-green-800"- >- You+ <div>+ <h2 class="text-xl leading-7 font-bold text-main">User list</h2>+ <BBTable+ class="mt-2"+ :columnList="columnList"+ :dataSource="memberList"+ :showHeader="true"+ :rowClickable="false"+ >+ <template v-slot:header>+ <BBTableHeaderCell+ :leftPadding="4"+ class="w-auto table-cell"+ :title="columnList[0].title"+ />+ <BBTableHeaderCell+ class="w-8 table-cell"+ :title="columnList[1].title"+ />+ <BBTableHeaderCell+ class="w-8 table-cell"+ :title="columnList[2].title"+ />+ <BBTableHeaderCell+ v-if="allowEdit"+ class="w-8 table-cell"+ :title="columnList[3].title"+ />+ </template>+ <template v-slot:body="{ rowData: member }">+ <BBTableCell :leftPadding="4" class="table-cell">+ <div class="flex flex-row items-center space-x-2">+ <BBAvatar :username="member.principal.name" />+ <div class="flex flex-col">+ <div class="flex flex-row items-center space-x-2">+ <router-link+ :to="`/u/${member.principal.id}`"+ class="normal-link"+ >{{ member.principal.name }}+ </router-link>+ <span+ v-if="currentUser.id == member.principal.id"+ class="inline-flex items-center px-2 py-0.5 rounded-lg text-xs font-semibold bg-green-100 text-green-800"+ >+ You+ </span>+ </div>+ <span class="textlabel">+ {{ member.principal.email }}</span></div>- <span class="textlabel">- {{ member.principal.email }}- </span></div>- </div>- </BBTableCell>- <BBTableCell>- <router-link :to="`/task/${member.taskId}`" class="normal-link"- >task/{{ member.taskId }}- </router-link>- </BBTableCell>- <BBTableCell>- {{ humanizeTs(member.createdTs) }}- </BBTableCell>- <BBTableCell>- <BBButtonTrash- v-if="allowEdit"- :requireConfirm="true"- :okText="'Revoke'"- :confirmTitle="`Are you sure to revoke access from '${member.principal.name}'`"- @confirm="deleteMember(member.id)"- />- </BBTableCell>- </template>- </BBTable>+ </BBTableCell>+ <BBTableCell>+ <router-link :to="`/task/${member.taskId}`" class="normal-link"+ >task/{{ member.taskId }}+ </router-link>+ </BBTableCell>+ <BBTableCell>+ {{ humanizeTs(member.createdTs) }}+ </BBTableCell>+ <BBTableCell>+ <BBButtonTrash+ v-if="allowEdit"+ :requireConfirm="true"+ :okText="'Revoke'"+ :confirmTitle="`Are you sure to revoke access from '${member.principal.name}'`"+ @confirm="deleteMember(member.id)"+ />+ </BBTableCell>+ </template>+ </BBTable>+ </div></template><script lang="ts">diff --git a/frontend/src/views/DataSourceDetail.vue b/frontend/src/views/DataSourceDetail.vueindex 73e5e73e84..f5e76b7e86 100644--- a/frontend/src/views/DataSourceDetail.vue+++ b/frontend/src/views/DataSourceDetail.vue@@ -196,143 +196,137 @@</div><div class="mt-6">- <div class="max-w-6xl mx-auto px-4">+ <div class="max-w-6xl mx-auto px-6 space-y-6"><!-- Description list -->- <div class="max-w-5xl mx-auto px-4 mb-6">- <dl class="grid grid-cols-1 gap-x-4 gap-y-8 sm:grid-cols-2">- <div class="sm:col-span-2">- <dt class="text-sm font-medium text-control-light">- Connection string- </dt>- <dd class="mt-2.5 text-sm text-main">- <div class="space-y-4">- <div- class="flex"- v-for="(connection, index) in connectionStringList"- :key="index"+ <dl class="grid grid-cols-1 gap-x-4 gap-y-4 sm:grid-cols-2">+ <div class="sm:col-span-2">+ <dt class="text-sm font-medium text-control-light">+ Connection string+ </dt>+ <dd class="mt-2.5 text-sm text-main">+ <div class="space-y-4">+ <div+ class="flex"+ v-for="(connection, index) in connectionStringList"+ :key="index"+ >+ <span+ class="whitespace-nowrap inline-flex items-center px-3 rounded-l-md border border-l border-r-0 border-control-border bg-gray-50 text-control-light sm:text-sm">- <span- class="whitespace-nowrap inline-flex items-center px-3 rounded-l-md border border-l border-r-0 border-control-border bg-gray-50 text-control-light sm:text-sm"- >- {{ connection.name }}- </span>- <span- class="flex-1 min-w-0 block w-full inline-flex items-center px-3 py-2 border border-r border-control-border sm:text-sm"- >- {{ connection.value }}- </span>- <button- class="-ml-px px-2 py-2 border border-gray-300 text-sm font-medium text-control-light bg-gray-50 hover:bg-gray-100 focus:ring-control focus:outline-none focus-visible:ring-2 focus:ring-offset-1"- @click.prevent="copyText(connection)"+ {{ connection.name }}+ </span>+ <span+ class="flex-1 min-w-0 block w-full inline-flex items-center px-3 py-2 border border-r border-control-border sm:text-sm"+ >+ {{ connection.value }}+ </span>+ <button+ class="-ml-px px-2 py-2 border border-gray-300 text-sm font-medium text-control-light bg-gray-50 hover:bg-gray-100 focus:ring-control focus:outline-none focus-visible:ring-2 focus:ring-offset-1"+ @click.prevent="copyText(connection)"+ >+ <svg+ class="w-6 h-6"+ fill="none"+ stroke="currentColor"+ viewBox="0 0 24 24"+ xmlns="http://www.w3.org/2000/svg">- <svg- class="w-6 h-6"- fill="none"- stroke="currentColor"- viewBox="0 0 24 24"- xmlns="http://www.w3.org/2000/svg"- >- <path- stroke-linecap="round"- stroke-linejoin="round"- stroke-width="2"- d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"- ></path>- </svg>- </button>- </div>+ <path+ stroke-linecap="round"+ stroke-linejoin="round"+ stroke-width="2"+ d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"+ ></path>+ </svg>+ </button></div>- </dd>- </div>+ </div>+ </dd>+ </div>- <div class="sm:col-span-1">- <dt class="text-sm font-medium text-control-light">- Username<span v-if="state.editing" class="text-red-600"- >*</span- >- </dt>- <dd class="mt-1 text-sm text-main">- <input- v-if="state.editing"- required- id="username"- type="text"- class="textfield"- v-model="state.editingDataSource.username"- />- <div v-else class="mt-2.5 mb-3">- {{ dataSource.username }}- </div>- </dd>- </div>+ <div class="sm:col-span-1">+ <dt class="text-sm font-medium text-control-light">+ Username<span v-if="state.editing" class="text-red-600">*</span>+ </dt>+ <dd class="mt-1 text-sm text-main">+ <input+ v-if="state.editing"+ required+ id="username"+ type="text"+ class="textfield"+ v-model="state.editingDataSource.username"+ />+ <div v-else class="mt-2.5 mb-3">+ {{ dataSource.username }}+ </div>+ </dd>+ </div>- <div class="sm:col-span-1">- <div class="flex items-center space-x-1">- <dt class="text-sm font-medium text-control-light">- Password- </dt>- <button- class="btn-icon"- @click.prevent="state.showPassword = !state.showPassword"+ <div class="sm:col-span-1">+ <div class="flex items-center space-x-1">+ <dt class="text-sm font-medium text-control-light">Password</dt>+ <button+ class="btn-icon"+ @click.prevent="state.showPassword = !state.showPassword"+ >+ <svg+ v-if="state.showPassword"+ class="w-5 h-5"+ fill="none"+ stroke="currentColor"+ viewBox="0 0 24 24"+ xmlns="http://www.w3.org/2000/svg">- <svg- v-if="state.showPassword"- class="w-5 h-5"- fill="none"- stroke="currentColor"- viewBox="0 0 24 24"- xmlns="http://www.w3.org/2000/svg"- >- <path- stroke-linecap="round"- stroke-linejoin="round"- stroke-width="2"- d="M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.88 9.88l-3.29-3.29m7.532 7.532l3.29 3.29M3 3l3.59 3.59m0 0A9.953 9.953 0 0112 5c4.478 0 8.268 2.943 9.543 7a10.025 10.025 0 01-4.132 5.411m0 0L21 21"- ></path>- </svg>- <svg- v-else- class="w-5 h-5"- fill="none"- stroke="currentColor"- viewBox="0 0 24 24"- xmlns="http://www.w3.org/2000/svg"- >- <path- stroke-linecap="round"- stroke-linejoin="round"- stroke-width="2"- d="M15 12a3 3 0 11-6 0 3 3 0 016 0z"- ></path>- <path- stroke-linecap="round"- stroke-linejoin="round"- stroke-width="2"- d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"- ></path>- </svg>- </button>- </div>- <dd class="mt-1 text-sm text-main">- <input- v-if="state.editing"- required- autocomplete="off"- id="password"- :type="state.showPassword ? 'text' : 'password'"- class="textfield"- v-model="state.editingDataSource.password"- />- <div v-else class="mt-2.5 mb-3">- <template v-if="state.showPassword">- {{ dataSource.password }}- </template>- <template v-else> ****** </template>- </div>- </dd>+ <path+ stroke-linecap="round"+ stroke-linejoin="round"+ stroke-width="2"+ d="M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.88 9.88l-3.29-3.29m7.532 7.532l3.29 3.29M3 3l3.59 3.59m0 0A9.953 9.953 0 0112 5c4.478 0 8.268 2.943 9.543 7a10.025 10.025 0 01-4.132 5.411m0 0L21 21"+ ></path>+ </svg>+ <svg+ v-else+ class="w-5 h-5"+ fill="none"+ stroke="currentColor"+ viewBox="0 0 24 24"+ xmlns="http://www.w3.org/2000/svg"+ >+ <path+ stroke-linecap="round"+ stroke-linejoin="round"+ stroke-width="2"+ d="M15 12a3 3 0 11-6 0 3 3 0 016 0z"+ ></path>+ <path+ stroke-linecap="round"+ stroke-linejoin="round"+ stroke-width="2"+ d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"+ ></path>+ </svg>+ </button></div>- </dl>- </div>+ <dd class="mt-1 text-sm text-main">+ <input+ v-if="state.editing"+ required+ autocomplete="off"+ id="password"+ :type="state.showPassword ? 'text' : 'password'"+ class="textfield"+ v-model="state.editingDataSource.password"+ />+ <div v-else class="mt-2.5 mb-3">+ <template v-if="state.showPassword">+ {{ dataSource.password }}+ </template>+ <template v-else> ****** </template>+ </div>+ </dd>+ </div>+ </dl><!-- Guard against dataSource.id != '-1', this could happen when we delete the data source --><DataSourceMemberTable@@ -342,7 +336,7 @@:dataSourceId="dataSource.id"/>- <div class="mt-6 flex justify-start">+ <div class="flex justify-start"><BBButtonTrashv-if="allowEdit":buttonText="'Delete this entire data source'"diff --git a/frontend/src/views/InstanceDetail.vue b/frontend/src/views/InstanceDetail.vueindex b37b969954..895fdf4a85 100644--- a/frontend/src/views/InstanceDetail.vue+++ b/frontend/src/views/InstanceDetail.vue@@ -13,7 +13,7 @@ input[type="number"] {</style><template>- <form class="px-4 space-y-6">+ <form class="px-6 space-y-6"><!-- Instance Name --><div class="grid grid-cols-1 gap-y-6 gap-x-4 sm:grid-cols-6"><div class="sm:col-span-2">