Merge branch 'main' into commuters
All checks were successful
LocalNet_front/pipeline/head This commit looks good
All checks were successful
LocalNet_front/pipeline/head This commit looks good
This commit is contained in:
commit
9e468d6ea9
@ -152,7 +152,7 @@ body {
|
||||
/* Consolas 폰트 */
|
||||
@font-face {
|
||||
font-family: 'Consolas';
|
||||
src: url('/font/Consolas.woff') format('woff');
|
||||
src: url('/font/Consolas.woff') format('font-woff');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@ -17,7 +17,7 @@
|
||||
<span>{{ date }}</span>
|
||||
<template v-if="showDetail">
|
||||
<span class="ms-2"> <i class="fa-regular fa-eye"></i> {{ views }} </span>
|
||||
<span class="ms-1"> <i class="bx bx-comment"></i> {{ commentNum }} </span>
|
||||
<span v-if="unknown" class="ms-1"> <i class="bx bx-comment"></i> {{ commentNum }} </span>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1,17 +1,21 @@
|
||||
<template>
|
||||
<div class="input-group mb-3 d-flex">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
placeholder="Search"
|
||||
v-model="searchQuery"
|
||||
@keyup.enter="search"
|
||||
@input="preventLeadingSpace"
|
||||
/>
|
||||
<button type="button" class="btn btn-primary" @click="search">
|
||||
<i class="bx bx-search bx-md"></i>
|
||||
</button>
|
||||
</div>
|
||||
<form @submit.prevent="search">
|
||||
<div class="input-group mb-3 d-flex">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
placeholder="Search"
|
||||
v-model="searchQuery"
|
||||
@input="preventLeadingSpace"
|
||||
/>
|
||||
<button
|
||||
type="submit"
|
||||
class="btn btn-primary"
|
||||
>
|
||||
<i class="bx bx-search bx-md"></i>
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
@ -28,15 +32,31 @@ const props = defineProps({
|
||||
const emits = defineEmits(["update:data"]);
|
||||
const searchQuery = ref("");
|
||||
|
||||
const search = function () {
|
||||
// Type Number 일때 maxlength 적용 안됨 방지
|
||||
if (searchQuery.value.length > props.maxlength) {
|
||||
searchQuery.value = searchQuery.value.slice(0, props.maxlength);
|
||||
// 검색 실행 함수 (버튼 클릭 or 엔터 공통)
|
||||
const search = () => {
|
||||
const trimmedQuery = searchQuery.value.trimStart();
|
||||
if (trimmedQuery === "") {
|
||||
emits("update:data", "");
|
||||
return;
|
||||
}
|
||||
if (trimmedQuery.length < 2 ) {
|
||||
alert("검색어는 최소 2글자 이상 입력해주세요.");
|
||||
searchQuery.value = '';
|
||||
return;
|
||||
}
|
||||
|
||||
// 길이 제한 처리
|
||||
if (trimmedQuery.length > props.maxlength) {
|
||||
searchQuery.value = trimmedQuery.slice(0, props.maxlength);
|
||||
} else {
|
||||
searchQuery.value = trimmedQuery;
|
||||
}
|
||||
|
||||
emits("update:data", searchQuery.value);
|
||||
};
|
||||
|
||||
const preventLeadingSpace = function () {
|
||||
// 좌측 공백 제거
|
||||
const preventLeadingSpace = () => {
|
||||
searchQuery.value = searchQuery.value.trimStart();
|
||||
};
|
||||
</script>
|
||||
|
||||
@ -29,6 +29,7 @@
|
||||
v-model="item.url"
|
||||
:is-essential="false"
|
||||
class="mb-1"
|
||||
:maxlength="maxLength"
|
||||
/>
|
||||
</div>
|
||||
<div class="d-flex justify-content align-items-center mt-3">
|
||||
@ -62,6 +63,7 @@ const contentAlerts = ref([false, false]);
|
||||
const titleAlert = ref(false);
|
||||
const title = ref('');
|
||||
const rink = ref('');
|
||||
const maxLength = ref(2000);
|
||||
const { itemList, addItem, removeItem } = voteCommon(true);
|
||||
const total = computed(() => props.total + itemList.value.length);
|
||||
const isSaveDisabled = computed(() => {
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="list-group">
|
||||
<label class="list-group-item">
|
||||
<label class="list-group-item" style="cursor: pointer;">
|
||||
<input
|
||||
class="form-check-input me-1"
|
||||
:name="data.LOCVOTSEQ"
|
||||
@ -10,7 +10,12 @@
|
||||
@change="handleChange"
|
||||
>
|
||||
{{ data.LOCVOTCON }}
|
||||
<a v-if="data.LOCVOTLIK" :href="data.LOCVOTLIK.startsWith('http') ? data.LOCVOTLIK : 'http://' + data.LOCVOTLIK" class="d-block text-truncate" target="_blank" rel="noopener noreferrer">
|
||||
<a :style="{ maxWidth: (data.LOCVOTLIK.length * 1) + 'ch' }"
|
||||
v-if="data.LOCVOTLIK"
|
||||
:href="data.LOCVOTLIK.startsWith('http') ? data.LOCVOTLIK : 'http://' + data.LOCVOTLIK"
|
||||
class="text-truncate"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer">
|
||||
{{ data.LOCVOTLIK }}
|
||||
</a>
|
||||
</label>
|
||||
@ -51,11 +56,15 @@ const handleChange = (event) => {
|
||||
}
|
||||
emit("update:selectedValues", updatedValues);
|
||||
};
|
||||
const preventLinkMove = (event) =>{
|
||||
event.preventDefault();
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
a {
|
||||
max-width: 500px; /* 원하는 너비로 조정 */
|
||||
display: block; /* 링크 텍스트에만 영역 적용 */
|
||||
max-width: 500px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
|
||||
@ -92,7 +92,7 @@
|
||||
@updateReaction="handleUpdateReaction"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div v-if="unknown">
|
||||
<!-- 댓글 입력 영역 -->
|
||||
<BoardCommentArea
|
||||
:profileName="profileName"
|
||||
@ -102,6 +102,7 @@
|
||||
:maxLength="500"
|
||||
@submitComment="handleCommentSubmit"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 댓글 목록 -->
|
||||
|
||||
@ -57,6 +57,7 @@
|
||||
v-model="item.url"
|
||||
:is-essential="false"
|
||||
class="mb-1"
|
||||
:maxlength="maxLength"
|
||||
/>
|
||||
<!-- <link-input v-model="item.url" class="mb-1"/> -->
|
||||
</div>
|
||||
@ -129,7 +130,7 @@ const { itemList, addItem, removeItem } = voteCommon();
|
||||
const userListTotal = ref(0);
|
||||
const addvoteitem = ref(false);
|
||||
const addvotemulti= ref(false);
|
||||
|
||||
const maxLength = ref(2000);
|
||||
const dateInput = ref(null);
|
||||
|
||||
const focusDateInput = () => {
|
||||
|
||||
@ -29,9 +29,8 @@
|
||||
<!-- 에러 메시지 -->
|
||||
<div v-if="error" class="fw-bold text-danger">{{ error }}</div>
|
||||
<!-- 단어 목록 -->
|
||||
<ul v-if="total > 0" class="ms-3 list-unstyled">
|
||||
<ul v-if="total > 0" class="ms-3 list-unstyled" style="overflow-x: hidden; word-wrap: break-word;">
|
||||
<DictCard
|
||||
class="DictCard"
|
||||
v-for="item in wordList"
|
||||
:key="item.WRDDICSEQ"
|
||||
:item="item"
|
||||
@ -152,8 +151,20 @@
|
||||
// 검색
|
||||
const search = (e) => {
|
||||
searchText.value = e.trim();
|
||||
getwordList(searchText.value, selectedAlphabet.value, selectedCategory.value);
|
||||
};
|
||||
if(searchText.value){
|
||||
getwordList(searchText.value, selectedAlphabet.value, selectedCategory.value);
|
||||
}else{
|
||||
if( selectedCategory.value !== '' && selectedCategory.value !== null){
|
||||
getwordList(searchText.value, selectedAlphabet.value, selectedCategory.value);
|
||||
}
|
||||
else if( selectedAlphabet.value !== '' && selectedAlphabet.value !== null){
|
||||
getwordList(searchText.value, selectedAlphabet.value, selectedCategory.value);
|
||||
}else{
|
||||
wordList.value = [];
|
||||
total.value = 0;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// 알파벳 선택
|
||||
const handleSelectedAlphabetChange = (newAlphabet) => {
|
||||
@ -281,8 +292,4 @@
|
||||
height: fit-content;
|
||||
}
|
||||
|
||||
.DictCard {
|
||||
grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
|
||||
gap: 1rem;
|
||||
}
|
||||
</style>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user