mirror of
https://github.com/logto-io/logto.git
synced 2025-01-27 21:39:16 -05:00
fix(console): icons in item preview should not be shrinked (#1234)
This commit is contained in:
parent
2a34684587
commit
2d663025ec
6 changed files with 36 additions and 23 deletions
|
@ -14,6 +14,10 @@
|
|||
flex: 1;
|
||||
}
|
||||
|
||||
.icon {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.pagination {
|
||||
margin-top: _.unit(4);
|
||||
min-height: 32px;
|
||||
|
|
|
@ -108,28 +108,31 @@ const ApiResources = () => {
|
|||
/>
|
||||
</TableEmpty>
|
||||
)}
|
||||
{apiResources?.map(({ id, name, indicator }) => (
|
||||
<tr
|
||||
key={id}
|
||||
className={tableStyles.clickable}
|
||||
onClick={() => {
|
||||
navigate(buildDetailsLink(id));
|
||||
}}
|
||||
>
|
||||
<td>
|
||||
<ItemPreview
|
||||
title={name}
|
||||
icon={
|
||||
theme === AppearanceMode.LightMode ? <ApiResource /> : <ApiResourceDark />
|
||||
}
|
||||
to={buildDetailsLink(id)}
|
||||
/>
|
||||
</td>
|
||||
<td>
|
||||
<CopyToClipboard value={indicator} variant="text" />
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
{apiResources?.map(({ id, name, indicator }) => {
|
||||
const ResourceIcon =
|
||||
theme === AppearanceMode.LightMode ? ApiResource : ApiResourceDark;
|
||||
|
||||
return (
|
||||
<tr
|
||||
key={id}
|
||||
className={tableStyles.clickable}
|
||||
onClick={() => {
|
||||
navigate(buildDetailsLink(id));
|
||||
}}
|
||||
>
|
||||
<td>
|
||||
<ItemPreview
|
||||
title={name}
|
||||
icon={<ResourceIcon className={styles.icon} />}
|
||||
to={buildDetailsLink(id)}
|
||||
/>
|
||||
</td>
|
||||
<td>
|
||||
<CopyToClipboard value={indicator} variant="text" />
|
||||
</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
|
|
@ -14,6 +14,10 @@
|
|||
flex: 1;
|
||||
}
|
||||
|
||||
.icon {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.pagination {
|
||||
margin-top: _.unit(4);
|
||||
min-height: 32px;
|
||||
|
|
|
@ -115,7 +115,7 @@ const Applications = () => {
|
|||
<ItemPreview
|
||||
title={name}
|
||||
subtitle={t(`${applicationTypeI18nKey[type]}.title`)}
|
||||
icon={<ApplicationIcon type={type} />}
|
||||
icon={<ApplicationIcon className={styles.icon} type={type} />}
|
||||
to={`/applications/${id}`}
|
||||
/>
|
||||
</td>
|
||||
|
|
|
@ -13,6 +13,7 @@ a.link {
|
|||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.logo {
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
height: 28px;
|
||||
border-radius: 6px;
|
||||
object-fit: cover;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.userName {
|
||||
|
|
Loading…
Add table
Reference in a new issue