Skip to content

Commit a9fbf5d

Browse files
committed
Migrated CSS of Testing History Panel File into Tailwind
Signed-off-by: Ayush <bhandariayush935@gmail.com>
1 parent 80189da commit a9fbf5d

3 files changed

Lines changed: 16 additions & 81 deletions

File tree

console/atest-ui/src/assets/main.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
@import './base.css';
22

3+
@tailwind base;
4+
@tailwind components;
5+
@tailwind utilities;
6+
37
#app {
48
margin: 0 auto;
59
height: 100vh;

console/atest-ui/src/views/TestingHistoryPanel.vue

Lines changed: 8 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import TestCase from './TestCase.vue'
33
import TemplateFunctions from './TemplateFunctions.vue'
44
import { ref, watch } from 'vue'
5+
import { API } from './net'
56
import { ElTree, ElMessage } from 'element-plus'
67
import { Refresh } from '@element-plus/icons-vue'
78
import { Cache } from './cache'
@@ -231,13 +232,13 @@ const viewName = ref('')
231232
</script>
232233

233234
<template>
234-
<div class="common-layout" data-title="Welcome!" data-intro="Welcome to use api-testing! 👋">
235-
<el-container style="height: 100%">
236-
<el-main style="padding-top: 5px; padding-bottom: 5px;">
237-
<el-container style="height: 100%">
235+
<div class="h-full" data-title="Welcome!" data-intro="Welcome to use api-testing! 👋">
236+
<el-container class="h-[100%]">
237+
<el-main class="pt-[5px] pb-[5px]">
238+
<el-container class="h-[100%]">
238239
<el-aside>
239240
<el-button type="primary" @click="loadStores" :icon="Refresh">{{ t('button.refresh') }}</el-button>
240-
<el-input v-model="filterText" :placeholder="t('tip.filter')" test-id="search" style="padding: 5px;" />
241+
<el-input v-model="filterText" :placeholder="t('tip.filter')" test-id="search" class="p-[5px]" />
241242
<el-tree
242243
v-loading="storesLoading"
243244
:data=treeData
@@ -254,9 +255,9 @@ const viewName = ref('')
254255
<TemplateFunctions />
255256
</el-aside>
256257

257-
<el-main style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px;">
258+
<el-main class="pt-[0px] pr-[0px] pb-[0px]">
258259
<TestCase v-if="viewName === 'testcase'" :suite="testSuite" :kindName="testKind" :name="testCaseName"
259-
:historySuiteName="historySuiteName" :historyCaseID="historyCaseID" @updated="loadStores" style="height: 100%;"
260+
:historySuiteName="historySuiteName" :historyCaseID="historyCaseID" @updated="loadStores" class="h-[100%]"
260261
data-intro="This is the test case editor. You can edit the test case here." />
261262
</el-main>
262263
</el-container>
@@ -265,77 +266,4 @@ const viewName = ref('')
265266
</div>
266267
</template>
267268

268-
<style scoped>
269-
header {
270-
line-height: 1.5;
271-
max-height: 100vh;
272-
}
273-
274-
.common-layout {
275-
height: 100%;
276-
}
277-
278-
.logo {
279-
display: block;
280-
margin: 0 auto 2rem;
281-
}
282-
283-
nav {
284-
width: 100%;
285-
font-size: 12px;
286-
text-align: center;
287-
margin-top: 2rem;
288-
}
289-
290-
nav a.router-link-exact-active {
291-
color: var(--color-text);
292-
}
293-
294-
nav a.router-link-exact-active:hover {
295-
background-color: transparent;
296-
}
297-
298-
nav a {
299-
display: inline-block;
300-
padding: 0 1rem;
301-
border-left: 1px solid var(--color-border);
302-
}
303269

304-
nav a:first-of-type {
305-
border: 0;
306-
}
307-
308-
@media (min-width: 1024px) {
309-
header {
310-
display: flex;
311-
place-items: center;
312-
padding-right: calc(var(--section-gap) / 2);
313-
}
314-
315-
.logo {
316-
margin: 0 2rem 0 0;
317-
}
318-
319-
header .wrapper {
320-
display: flex;
321-
place-items: flex-start;
322-
flex-wrap: wrap;
323-
}
324-
325-
nav {
326-
text-align: left;
327-
margin-left: -1rem;
328-
font-size: 1rem;
329-
330-
padding: 1rem 0;
331-
margin-top: 1rem;
332-
}
333-
}
334-
335-
.demo-tabs>.el-tabs__content {
336-
padding: 32px;
337-
color: #6b778c;
338-
font-size: 32px;
339-
font-weight: 600;
340-
}
341-
</style>

console/atest-ui/tailwind.config.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
/** @type {import('tailwindcss').Config} */
22
module.exports = {
3-
content: [],
3+
content: [
4+
"./index.html",
5+
"./src/**/*.{vue,js,ts,jsx,tsx}",
6+
],
47
theme: {
58
extend: {},
69
},

0 commit comments

Comments
 (0)