Skip to content

Commit

Permalink
Minor improvements in UI (#1399)
Browse files Browse the repository at this point in the history
  • Loading branch information
TaraRostami committed Dec 17, 2023
1 parent 9b60b0f commit 495bfb9
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 20 deletions.
15 changes: 14 additions & 1 deletion web/assets/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@ style attribute {
.dark .ant-table-row-expand-icon {
color: #fff;
background-color: #fff0;
border-color: #9ea2a8;
border-color: rgb(255 255 255 / 20%);
}

.dark .ant-table-row-expand-icon:hover {
Expand Down Expand Up @@ -1099,3 +1099,16 @@ li.ant-select-dropdown-menu-item:empty:after {
max-height: 400px;
overflow-y: auto;
}

.ant-table-row-expand-icon {
border-radius: 6px;
}

.qr-bg {
background-color: #fff;
display: flex;
justify-content: center;
align-content: center;
padding: 0.5rem;
border-radius: 1rem;
}
6 changes: 3 additions & 3 deletions web/html/common/qrcode_modal.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@
</a-tag>
<template v-if="app.subSettings.enable && qrModal.subId">
<a-divider>Subscription</a-divider>
<canvas @click="copyToClipboard('qrCode-sub',genSubLink(qrModal.client.subId))" id="qrCode-sub" style="width: 100%; height: 100%;"></canvas>
<div class="qr-bg"><canvas @click="copyToClipboard('qrCode-sub',genSubLink(qrModal.client.subId))" id="qrCode-sub" style="width: 100%; height: 100%;"></canvas></div>
</template>
<a-divider>{{ i18n "pages.inbounds.client" }}</a-divider>
<template v-for="(row, index) in qrModal.qrcodes">
<a-tag color="green" style="margin: 10px 0; display: block; text-align: center;">[[ row.remark ]]</a-tag>
<canvas @click="copyToClipboard('qrCode-'+index, row.link)" :id="'qrCode-'+index" style="width: 100%; height: 100%;"></canvas>
<div class="qr-bg"><canvas @click="copyToClipboard('qrCode-'+index, row.link)" :id="'qrCode-'+index" style="width: 100%; height: 100%;"></canvas></div>
</template>
</a-modal>

Expand Down Expand Up @@ -87,4 +87,4 @@
});

</script>
{{end}}
{{end}}
5 changes: 3 additions & 2 deletions web/html/login.html
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,9 @@
background-origin: border-box;
background-clip: padding-box, border-box;
background-size: 300%;
transition: all 0.5s ease;
transition: all 0.3s cubic-bezier(.645,.045,.355,1);
width: 100%;
z-index: 1;
}
.dark .wave-btn-bg:hover {animation: wave-btn-tara 4s ease infinite;}
.dark .wave-btn-bg-cl {
Expand Down Expand Up @@ -289,7 +290,7 @@ <h1 class="title">{{ i18n "pages.login.title" }}</h1>
</a-form-item>
<a-form-item>
<a-row justify="center" class="centered">
<div class="wave-btn-bg wave-btn-bg-cl">
<div class="wave-btn-bg wave-btn-bg-cl" :style="loading ? { width: '54px' } : { display: 'inline-block' }">
<a-button class="ant-btn-primary-login" type="primary" :loading="loading" @click="login" :icon="loading ? 'poweroff' : undefined"
:style="loading ? { width: '50px' } : { display: 'inline-block' }">
[[ loading ? '' : '{{ i18n "login" }}' ]]
Expand Down
4 changes: 2 additions & 2 deletions web/html/xui/form/stream/stream_grpc.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{{define "form/streamGRPC"}}
<a-form :colon="false" :label-col="{ md: {span:6} }" :wrapper-col="{ md: {span:14} }">
<a-form-item label="Service Name">
<a-input v-model.trim="inbound.stream.grpc.serviceName" style="width: 250px;"></a-input>
<a-input v-model.trim="inbound.stream.grpc.serviceName"></a-input>
</a-form-item>
<a-form-item label="MultiMode">
<a-switch v-model="inbound.stream.grpc.multiMode"></a-switch>
</a-form-item>
</a-form>
{{end}}
{{end}}
22 changes: 11 additions & 11 deletions web/html/xui/form/tls_settings.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,10 @@
</a-form-item>
<template v-if="cert.useFile">
<a-form-item label='{{ i18n "pages.inbounds.publicKeyPath" }}'>
<a-input v-model.trim="cert.certFile" style="width:250px;"></a-input>
<a-input v-model.trim="cert.certFile"></a-input>
</a-form-item>
<a-form-item label='{{ i18n "pages.inbounds.keyPath" }}'>
<a-input v-model.trim="cert.keyFile" style="width:250px;"></a-input>
<a-input v-model.trim="cert.keyFile"></a-input>
</a-form-item>
<a-form-item label=" ">
<a-button type="primary" icon="import" @click="setDefaultCertData(index)">{{ i18n
Expand All @@ -86,10 +86,10 @@
</template>
<template v-else>
<a-form-item label='{{ i18n "pages.inbounds.publicKeyContent" }}'>
<a-input type="textarea" :rows="3" style="width:250px;" v-model="cert.cert"></a-input>
<a-input type="textarea" :rows="3" v-model="cert.cert"></a-input>
</a-form-item>
<a-form-item label='{{ i18n "pages.inbounds.keyContent" }}'>
<a-input type="textarea" :rows="3" style="width:250px;" v-model="cert.key"></a-input>
<a-input type="textarea" :rows="3" v-model="cert.key"></a-input>
</a-form-item>
</template>
<a-form-item label='ocspStapling'>
Expand Down Expand Up @@ -125,10 +125,10 @@
</a-form-item>
<template v-if="cert.useFile">
<a-form-item label='{{ i18n "pages.inbounds.publicKeyPath" }}'>
<a-input v-model.trim="cert.certFile" style="width:250px;"></a-input>
<a-input v-model.trim="cert.certFile"></a-input>
</a-form-item>
<a-form-item label='{{ i18n "pages.inbounds.keyPath" }}'>
<a-input v-model.trim="cert.keyFile" style="width:250px;"></a-input>
<a-input v-model.trim="cert.keyFile"></a-input>
</a-form-item>
<a-form-item label=" ">
<a-button type="primary" icon="import" @click="setDefaultCertXtls(index)">{{ i18n
Expand All @@ -137,10 +137,10 @@
</template>
<template v-else>
<a-form-item label='{{ i18n "pages.inbounds.publicKeyContent" }}'>
<a-input type="textarea" :rows="3" style="width:250px;" v-model="cert.cert"></a-input>
<a-input type="textarea" :rows="3" v-model="cert.cert"></a-input>
</a-form-item>
<a-form-item label='{{ i18n "pages.inbounds.keyContent" }}'>
<a-input type="textarea" :rows="3" style="width:250px;" v-model="cert.key"></a-input>
<a-input type="textarea" :rows="3" v-model="cert.key"></a-input>
</a-form-item>
</template>
</template>
Expand Down Expand Up @@ -175,10 +175,10 @@
<a-icon @click="inbound.stream.reality.shortIds = RandomUtil.randomShortId()" type="sync"> </a-icon>
</a-icon>
</template>
<a-input v-model.trim="inbound.stream.reality.shortIds" style="width:250px"></a-input>
<a-input v-model.trim="inbound.stream.reality.shortIds"></a-input>
</a-form-item>
<a-form-item label='SpiderX'>
<a-input v-model.trim="inbound.stream.reality.settings.spiderX" style="width:250px"></a-input>
<a-input v-model.trim="inbound.stream.reality.settings.spiderX"></a-input>
</a-form-item>
<a-form-item label='Private Key'>
<a-input v-model.trim="inbound.stream.reality.privateKey"></a-input>
Expand All @@ -191,4 +191,4 @@
</a-form-item>
</template>
</a-form>
{{end}}
{{end}}
2 changes: 1 addition & 1 deletion web/html/xui/inbounds.html
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@
:columns="isMobile ? innerMobileColumns : innerColumns"
:data-source="getInboundClients(record)"
:pagination=pagination(getInboundClients(record))
style="margin: -12px 2px -13px;">
:style="isMobile ? 'margin: -12px 2px -13px;' : 'margin: -12px 22px -13px;'">
{{template "client_table"}}
</a-table>
</template>
Expand Down

0 comments on commit 495bfb9

Please sign in to comment.