first commit 2
This commit is contained in:
@@ -0,0 +1,105 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 180);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 150);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 1열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 1;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 1;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
$rb_skin['md_id'] 설정ID
|
||||
$rb_skin['md_layout'] 레이아웃 섹션ID
|
||||
$rb_skin['md_layout_name'] 레이아웃 스킨명
|
||||
$rb_skin['md_theme'] 테마명
|
||||
$rb_skin['md_title'] 타이틀(제목)
|
||||
$rb_skin['md_bo_table'] 게시판ID
|
||||
$rb_skin['md_skin'] 스킨명
|
||||
$rb_skin['md_cnt'] 출력갯수
|
||||
$rb_skin['md_col'] 행갯수
|
||||
$rb_skin['md_row'] 열갯수
|
||||
$rb_skin['md_col_mo'] 행갯수(모바일)
|
||||
$rb_skin['md_row_mo'] 열갯수(모바일)
|
||||
$rb_skin['md_gap'] 게시물 간격(여백)
|
||||
$rb_skin['md_gap_mo'] 모바일 게시물 간격(여백)
|
||||
$rb_skin['md_width'] 가로사이즈
|
||||
$rb_skin['md_height'] 세로사이즈
|
||||
$rb_skin['md_auto_time'] 자동롤링 시간
|
||||
$rb_skin['md_thumb_is'] 썸네일 출력여부(1,0)
|
||||
$rb_skin['md_nick_is'] 닉네임 출력여부(1,0)
|
||||
$rb_skin['md_date_is'] 작성일 출력여부(1,0)
|
||||
$rb_skin['md_content_is'] 본문내용 출력여부(1,0)
|
||||
$rb_skin['md_icon_is'] 아이콘 출력여부(1,0)
|
||||
$rb_skin['md_comment_is'] 댓글수 출력여부(1,0)
|
||||
$rb_skin['md_swiper_is'] 스와이프 여부(1,0)
|
||||
$rb_skin['md_auto_is'] 자동롤링 여부(1,0)
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-basic-skin" style="<?php echo $css_vars; ?>">
|
||||
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</li>
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="basic-list-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
<?php } ?>
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,62 @@
|
||||
/* Latest Basic Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-basic-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
/* 💡 [핵심 수정] Flexbox 컬럼 방향으로 설정하여 세로 배치 강제 */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-basic-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0; /* 타이틀 영역이 찌그러지지 않도록 */
|
||||
}
|
||||
|
||||
.latest-basic-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-basic-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-basic-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-basic-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-basic-skin .cb { display: none; }
|
||||
|
||||
.basic-list-grid {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 1), 1fr);
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.latest-basic-skin li { padding: 8px 0; border-bottom: 1px solid #f5f5f5; }
|
||||
.latest-basic-skin li:last-child { border-bottom: 1px solid #f5f5f5; }
|
||||
.latest-basic-skin li a { display: flex; align-items: center; text-decoration: none; color: #555; transition: color 0.2s; }
|
||||
.latest-basic-skin li a:hover { color: #0056b3; }
|
||||
.latest-basic-skin li img { width: 40px; height: 40px; object-fit: cover; border-radius: 4px; margin-right: 10px; flex-shrink: 0; }
|
||||
.latest-basic-skin li .no-img { display: none; }
|
||||
.latest-basic-skin .subject { flex-grow: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
|
||||
.latest-basic-skin .date { font-size: 12px; color: #999; margin-left: 10px; flex-shrink: 0; }
|
||||
.empty_li { grid-column: 1 / -1; text-align: center; padding: 50px 0; color: #999; }
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.basic-list-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 200);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 150);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 4열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 4;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 2;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-gallery-skin" style="<?php echo $css_vars; ?>">
|
||||
<!-- 표준 타이틀 영역 -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</li>
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="gallery-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<a href="<?php echo $list[$i]['href'] ?>" class="lt_img">
|
||||
<?php
|
||||
if ($thumb['src']) {
|
||||
echo "<img src=\"".$thumb['src']."\" alt=\"".$thumb['alt']."\" >";
|
||||
} else {
|
||||
echo "<span>No Image</span>";
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
<a href="<?php echo $list[$i]['href'] ?>" class="lt_tit"><?php echo $list[$i]['subject']; ?></a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,59 @@
|
||||
/* Latest Gallery Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-gallery-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
/* 💡 [핵심 수정] Flexbox 컬럼 방향으로 설정하여 세로 배치 강제 */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-gallery-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-gallery-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-gallery-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-gallery-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-gallery-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-gallery-skin .cb { display: none; }
|
||||
|
||||
.gallery-grid {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 4), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
.latest-gallery-skin li { position: relative; overflow: hidden; border-radius: 8px; box-shadow: 0 2px 5px rgba(0,0,0,0.05); transition: transform 0.3s; }
|
||||
.latest-gallery-skin li:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
|
||||
.latest-gallery-skin .lt_img { display: block; width: 100%; padding-top: 75%; position: relative; background: #f8f8f8; }
|
||||
.latest-gallery-skin .lt_img img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
|
||||
.latest-gallery-skin .lt_tit { display: block; padding: 10px; font-size: 14px; font-weight: 500; color: #333; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: #fff; }
|
||||
.empty_li { grid-column: 1 / -1; text-align: center; padding: 50px 0; color: #999; }
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.gallery-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 2), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,96 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 400);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 300);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [수정] 컬럼 수 설정값 확인 및 기본값 5로 변경 (사용자 요청 반영)
|
||||
// md_col 값이 0이거나 비어있으면 5로 설정
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 5;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 2;
|
||||
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
// 내용 표시 여부에 따라 클래스 결정
|
||||
$content_class = $rb_skin['md_content_is'] ? 'has-content' : 'image-only';
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-main-visual-skin <?php echo $content_class; ?>" style="<?php echo $css_vars; ?>">
|
||||
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
|
||||
<ul class="visual-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
$thumb_src = $thumb['src'] ?: G5_THEME_URL . '/rb.img/no_image.png';
|
||||
?>
|
||||
<li class="visual-item">
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="visual-image">
|
||||
<img src="<?php echo $thumb_src; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($rb_skin['md_content_is'] || $rb_skin['md_subject_is']) { ?>
|
||||
<div class="visual-text">
|
||||
<?php if ($rb_skin['md_subject_is']) { ?>
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($rb_skin['md_content_is']) { ?>
|
||||
<p class="content"><?php echo cut_str(strip_tags($list[$i]['wr_content']), 80); ?></p>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,167 @@
|
||||
/* Latest Main Visual Skin Style - Title Fix */
|
||||
|
||||
.latest-main-visual-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-main-visual-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-main-visual-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-main-visual-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;
|
||||
}
|
||||
.latest-main-visual-skin .cb { display: none; }
|
||||
|
||||
/* --- 이하 기존 스타일 유지 --- */
|
||||
|
||||
.visual-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 4), 1fr);
|
||||
gap: 15px;
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.visual-item {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 5px rgba(0,0,0,0.05);
|
||||
transition: transform 0.3s;
|
||||
background: #fff;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.visual-item:hover {
|
||||
transform: translateY(-5px);
|
||||
box-shadow: 0 5px 15px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.visual-item a {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
text-decoration: none;
|
||||
color: inherit;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.image-only .visual-image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
padding-top: 75%;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.image-only .visual-image img {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.image-only .visual-text {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.has-content .visual-image {
|
||||
width: 100%;
|
||||
height: 150px;
|
||||
position: relative;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.has-content .visual-image img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.has-content .visual-text {
|
||||
padding: 15px;
|
||||
flex-grow: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
background: #fff;
|
||||
border-top: 1px solid #f0f0f0;
|
||||
}
|
||||
|
||||
.visual-text .subject {
|
||||
display: block;
|
||||
font-size: 16px;
|
||||
font-weight: 600;
|
||||
color: #333;
|
||||
margin-bottom: 8px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.visual-text .content {
|
||||
font-size: 13px;
|
||||
color: #666;
|
||||
line-height: 1.5;
|
||||
margin: 0;
|
||||
display: -webkit-box;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
max-height: 3em;
|
||||
}
|
||||
|
||||
.empty_li {
|
||||
grid-column: 1 / -1;
|
||||
text-align: center;
|
||||
padding: 50px 0;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.visual-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 2), 1fr);
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.latest-main-visual-skin.has-content .visual-image {
|
||||
height: 120px;
|
||||
}
|
||||
|
||||
.visual-text {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.visual-text .subject {
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 300);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 200);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-main-visual-item-skin">
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
|
||||
<div class="item-list">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<div class="item-box">
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="item-img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<div class="item-text">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<div class="empty_li">게시물이 없습니다.</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,44 @@
|
||||
/* Latest Main Visual Item Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-main-visual-item-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-main-visual-item-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-item-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-main-visual-item-skin.bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-main-visual-item-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-main-visual-item-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-main-visual-item-skin .cb { display: none; }
|
||||
|
||||
.latest-main-visual-item-skin .item-list {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 3), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.latest-main-visual-item-skin .item-list {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = 150;//(int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 300);
|
||||
$thumb_height = 150;//(int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 200);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
$css_vars = "--pc-columns: 5; --mo-columns: 1;";
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
$rb_skin['md_id']; // 모듈아이디
|
||||
$rb_skin['md_col']; // 열
|
||||
$rb_skin['md_row']; // 행
|
||||
$rb_skin['md_subject_is']; // 상품명 출력여부
|
||||
$rb_skin['md_thumb_is']; // 이미지 출력여부
|
||||
$rb_skin['md_date_is']; // 등록일 출력 여부
|
||||
$rb_skin['md_ca_is']; // 카테고리명 출력 여부
|
||||
$rb_skin['md_comment_is']; // 찜갯수 출력 여부
|
||||
$rb_skin['md_content_is']; // 상품간략설명 출력 여부
|
||||
$rb_skin['md_icon_is']; // 아이콘 출력 여부
|
||||
$rb_skin['md_gap']; // 여백
|
||||
$rb_skin['md_gap_mo']; // 모바일 여백
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-main-visual-item-col-skin" style="<?php echo $css_vars ?>">
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
|
||||
<div class="item-list">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<div class="item-box">
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="item-img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<div class="item-text">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<div class="empty_li">게시물이 없습니다.</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,44 @@
|
||||
/* Latest Main Visual Item Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-main-visual-item-col-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-main-visual-item-col-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-item-col-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-main-visual-item-col-skin.bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-main-visual-item-col-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-main-visual-item-col-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 0px 10px !important;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-main-visual-item-col-skin .cb { display: none; }
|
||||
|
||||
.latest-main-visual-item-col-skin .item-list {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 3), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
@media (max-width: 760px) {
|
||||
.latest-main-visual-item-col-skin .item-list {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-main-visual-list-skin">
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
|
||||
<ul>
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<span class="lt_img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</span>
|
||||
<?php } ?>
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,38 @@
|
||||
/* Latest Main Visual List Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-main-visual-list-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-main-visual-list-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-list-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-main-visual-list-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-main-visual-list-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-main-visual-list-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-main-visual-list-skin .cb { display: none; }
|
||||
|
||||
.latest-main-visual-list-skin ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-main-visual-menu-skin">
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
|
||||
<ul class="menu-list">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,38 @@
|
||||
/* Latest Main Visual Menu Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-main-visual-menu-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-main-visual-menu-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-main-visual-menu-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-main-visual-menu-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-main-visual-menu-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-main-visual-menu-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-main-visual-menu-skin .cb { display: none; }
|
||||
|
||||
.latest-main-visual-menu-skin .menu-list {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 이 스킨 전용 CSS, JS 파일을 불러옵니다.
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
// add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="module_latest_wrap">
|
||||
<section class="issue-ticker-module">
|
||||
|
||||
<!-- 💡 [수정] 표준 타이틀 영역 적용 -->
|
||||
<div class="issue-header" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#0056b3'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '16'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<!-- 💡 [수정] scrollVert -> scrollUp (기본 효과 사용) -->
|
||||
<div class="issue-content cycle-slideshow"
|
||||
data-cycle-fx="scrollUp"
|
||||
data-cycle-slides="> a"
|
||||
data-cycle-timeout="3000"
|
||||
data-cycle-prev=".issue-ticker-module .btn-prev"
|
||||
data-cycle-next=".issue-ticker-module .btn-next"
|
||||
data-cycle-reverse="false"
|
||||
data-cycle-log="false"
|
||||
>
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
?>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php
|
||||
echo $list[$i]['subject'];
|
||||
|
||||
if ($rb_skin['md_comment_is'] && $list[$i]['comment_cnt']) {
|
||||
echo " <span class='comment_count'>".$list[$i]['comment_cnt']."</span>";
|
||||
}
|
||||
if ($rb_skin['md_icon_is'] && $list[$i]['icon_new']) {
|
||||
echo " <span class='new_icon'>N</span>";
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<div class="empty-latest">게시물이 없습니다.</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<div class="issue-controls">
|
||||
<button type="button" class="btn-prev" aria-label="이전"></button>
|
||||
<button type="button" class="btn-next" aria-label="다음"></button>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
<script>
|
||||
(function() {
|
||||
// 💡 [수정] $md_id 대신 $rb_skin['md_id'] 사용
|
||||
const currentModuleId = 'ns-<?php echo $rb_skin['md_id']; ?>';
|
||||
const initFunctionName = 'initNoticeModule'; // script.js에 이 함수가 있어야 함
|
||||
const scriptId = 'notice-module-script-' + currentModuleId;
|
||||
|
||||
if (document.getElementById(scriptId)) {
|
||||
if (typeof window[initFunctionName] === 'function') {
|
||||
window[initFunctionName](currentModuleId);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
const script = document.createElement('script');
|
||||
script.id = scriptId;
|
||||
script.src = '<?php echo $latest_skin_url; ?>/script.js?ver=<?php echo G5_JS_VER; ?>';
|
||||
script.async = true;
|
||||
|
||||
script.onload = () => {
|
||||
if (typeof window[initFunctionName] === 'function') {
|
||||
window[initFunctionName](currentModuleId);
|
||||
}
|
||||
return;
|
||||
};
|
||||
document.head.appendChild(script);
|
||||
})();
|
||||
</script>
|
||||
@@ -0,0 +1,19 @@
|
||||
(function($) {
|
||||
"use strict";
|
||||
|
||||
$(function() {
|
||||
// 각 뉴스 티커 모듈에 대해 개별적으로 Cycle2를 초기화합니다.
|
||||
$('.issue-ticker-module').each(function() {
|
||||
var $this = $(this);
|
||||
var $content = $this.find('.issue-content');
|
||||
|
||||
// 이미 초기화되었다면 중복 실행 방지
|
||||
if ($content.data('cycle.opts')) {
|
||||
return;
|
||||
}
|
||||
|
||||
$content.cycle();
|
||||
});
|
||||
});
|
||||
|
||||
})(jQuery);
|
||||
@@ -0,0 +1,77 @@
|
||||
/* News Ticker Latest Skin Style - Title Fix */
|
||||
|
||||
.issue-ticker-module {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
border: 1px solid #e0e0e0;
|
||||
padding: 10px 15px;
|
||||
background: #f9f9f9;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* 💡 [핵심 수정] 타이틀 영역 Flexbox로 변경 */
|
||||
.issue-header {
|
||||
margin-right: 15px;
|
||||
flex-shrink: 0;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.issue-header h2 {
|
||||
margin: 0;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.issue-content {
|
||||
flex-grow: 1;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
height: 24px; /* 한 줄 높이 */
|
||||
}
|
||||
|
||||
.issue-content a {
|
||||
display: block;
|
||||
line-height: 24px;
|
||||
text-decoration: none;
|
||||
color: #333;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.issue-controls {
|
||||
margin-left: 15px;
|
||||
display: flex;
|
||||
gap: 5px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.issue-controls button {
|
||||
background: none;
|
||||
border: 1px solid #ccc;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.issue-controls button:before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
border: solid #555;
|
||||
border-width: 0 2px 2px 0;
|
||||
display: inline-block;
|
||||
padding: 3px;
|
||||
}
|
||||
|
||||
.issue-controls .btn-prev:before {
|
||||
transform: translate(-50%, -50%) rotate(135deg); /* 위쪽 화살표 */
|
||||
}
|
||||
|
||||
.issue-controls .btn-next:before {
|
||||
transform: translate(-50%, -50%) rotate(-45deg); /* 아래쪽 화살표 */
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 200);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 150);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 4열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 4;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 2;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-pic-block-skin" style="<?php echo $css_vars; ?>">
|
||||
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
<ul class="pic-block-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<a href="<?php echo $list[$i]['href'] ?>" class="lt_img">
|
||||
<?php
|
||||
if ($thumb['src']) {
|
||||
echo "<img src=\"".$thumb['src']."\" alt=\"".$thumb['alt']."\" >";
|
||||
} else {
|
||||
echo "<span>No Image</span>";
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
<a href="<?php echo $list[$i]['href'] ?>" class="lt_tit"><?php echo $list[$i]['subject']; ?></a>
|
||||
<?php if ($rb_skin['md_content_is']) { ?>
|
||||
<p class="lt_content"><?php echo cut_str(strip_tags($list[$i]['wr_content']), 100); ?></p>
|
||||
<?php } ?>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,60 @@
|
||||
/* Latest Pic Block Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-pic-block-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
/* 💡 [핵심 수정] Flexbox 컬럼 방향으로 설정하여 세로 배치 강제 */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-pic-block-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-pic-block-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-pic-block-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-block-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-pic-block-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-pic-block-skin .cb { display: none; }
|
||||
|
||||
.pic-block-grid {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 4), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
.latest-pic-block-skin li { position: relative; overflow: hidden; border-radius: 8px; box-shadow: 0 2px 5px rgba(0,0,0,0.05); transition: transform 0.3s; background: #fff; display: flex; flex-direction: column; }
|
||||
.latest-pic-block-skin li:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
|
||||
.latest-pic-block-skin .lt_img { display: block; width: 100%; padding-top: 60%; position: relative; background: #f8f8f8; }
|
||||
.latest-pic-block-skin .lt_img img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
|
||||
.latest-pic-block-skin .lt_tit { display: block; padding: 10px 10px 5px; font-size: 15px; font-weight: 600; color: #333; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-block-skin .lt_content { padding: 0 10px 15px; font-size: 13px; color: #666; line-height: 1.5; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; height: 3em; }
|
||||
.empty_li { grid-column: 1 / -1; text-align: center; padding: 50px 0; color: #999; }
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.pic-block-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 2), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,93 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 1열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 1;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 1;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-pic-list-skin" style="<?php echo $css_vars; ?>">
|
||||
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">리스트 +</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
<ul class="pic-list-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<a href="<?php echo $list[$i]['href']; ?>" class="lt_img">
|
||||
<?php
|
||||
if ($thumb['src']) {
|
||||
echo "<img src=\"".$thumb['src']."\" alt=\"".$thumb['alt']."\">";
|
||||
} else {
|
||||
echo "<span>No Image</span>";
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
<div class="lt_txt_wrap">
|
||||
<a href="<?php echo $list[$i]['href']; ?>" class="lt_tit"><?php echo cut_str($list[$i]['subject'], 10); ?></a>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="lt_date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,62 @@
|
||||
/* Latest Pic List Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-pic-list-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
/* 💡 [핵심 수정] Flexbox 컬럼 방향으로 설정하여 세로 배치 강제 */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-pic-list-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-pic-list-skin .cb { display: none; }
|
||||
|
||||
.pic-list-grid {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 1), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin li { display: flex; align-items: flex-start; padding: 15px 0; border-bottom: 1px solid #f0f0f0; }
|
||||
.latest-pic-list-skin li:last-child { border-bottom: 1px solid #f0f0f0; }
|
||||
.latest-pic-list-skin .lt_img { display: block; width: 100px; height: 75px; flex-shrink: 0; margin-right: 15px; border-radius: 4px; overflow: hidden; background: #f8f8f8; }
|
||||
.latest-pic-list-skin .lt_img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
|
||||
.latest-pic-list-skin li:hover .lt_img img { transform: scale(1.05); }
|
||||
.latest-pic-list-skin .lt_txt_wrap { flex-grow: 1; min-width: 0; }
|
||||
.latest-pic-list-skin .lt_tit { display: block; font-size: 15px; font-weight: 600; color: #333; text-decoration: none; margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-list-skin .lt_date { font-size: 12px; color: #999; display: block; }
|
||||
.empty_li { grid-column: 1 / -1; text-align: center; padding: 50px 0; color: #999; }
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.pic-list-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,95 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 1열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 1;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 1;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
|
||||
<div class="latest-pic-list-skin" style="<?php echo $css_vars; ?>">
|
||||
|
||||
<!-- { -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<!-- 타이틀 { -->
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
<!-- } -->
|
||||
</li>
|
||||
|
||||
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">리스트 +</button>
|
||||
</li>
|
||||
|
||||
<div class="cb"></div>
|
||||
</ul>
|
||||
<!-- } -->
|
||||
<ul class="pic-list-grid">
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
// 💡 [수정] 제목 길이 10자로 제한
|
||||
$subject = cut_str(strip_tags($list[$i]['wr_subject']), 10);
|
||||
?>
|
||||
<li>
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<a href="<?php echo $list[$i]['href']; ?>" class="lt_img">
|
||||
<?php
|
||||
if ($thumb['src']) {
|
||||
echo "<img src=\"".$thumb['src']."\" alt=\"".$thumb['alt']."\">";
|
||||
} else {
|
||||
echo "<span>No Image</span>";
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
<div class="lt_txt_wrap">
|
||||
<a href="<?php echo $list[$i]['href']; ?>" class="lt_tit"><?php echo $subject; ?></a>
|
||||
<?php if ($rb_skin['md_date_is']) { ?>
|
||||
<span class="lt_date"><?php echo $list[$i]['datetime2'] ?></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,62 @@
|
||||
/* Latest Pic List Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-pic-list-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
/* 💡 [핵심 수정] Flexbox 컬럼 방향으로 설정하여 세로 배치 강제 */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-list-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-pic-list-skin .more_btn {
|
||||
position: relative; /* 💡 [핵심 수정] absolute 속성 덮어쓰기 */
|
||||
background: none;
|
||||
border: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;}
|
||||
.latest-pic-list-skin .cb { display: none; }
|
||||
|
||||
.pic-list-grid {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 1), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
.latest-pic-list-skin li { display: flex; align-items: flex-start; padding: 15px 0; border-bottom: 1px solid #f0f0f0; }
|
||||
.latest-pic-list-skin li:last-child { border-bottom: 1px solid #f0f0f0; }
|
||||
.latest-pic-list-skin .lt_img { display: block; width: 100px; height: 75px; flex-shrink: 0; margin-right: 15px; border-radius: 4px; overflow: hidden; background: #f8f8f8; }
|
||||
.latest-pic-list-skin .lt_img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
|
||||
.latest-pic-list-skin li:hover .lt_img img { transform: scale(1.05); }
|
||||
.latest-pic-list-skin .lt_txt_wrap { flex-grow: 1; min-width: 0; }
|
||||
.latest-pic-list-skin .lt_tit { display: block; font-size: 15px; font-weight: 600; color: #333; text-decoration: none; margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-pic-list-skin .lt_date { font-size: 12px; color: #999; display: block; }
|
||||
.empty_li { grid-column: 1 / -1; text-align: center; padding: 50px 0; color: #999; }
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.pic-list-grid {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 1열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 1;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 1;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-thumb-left-skin" style="<?php echo $css_vars; ?>">
|
||||
<!-- 표준 타이틀 영역 -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</li>
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul>
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="lt_img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<div class="lt_txt">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_content_is']) { ?>
|
||||
<p class="content"><?php echo cut_str(strip_tags($list[$i]['wr_content']), 100); ?></p>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Latest Thumb Left Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-thumb-left-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-thumb-left-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-thumb-left-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-thumb-left-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-thumb-left-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-thumb-left-skin .more_btn { position: relative; background: none; border: 1px solid #ddd; padding: 5px 10px; font-size: 12px; color: #666; cursor: pointer; border-radius: 3px; }
|
||||
.latest-thumb-left-skin .cb { display: none; }
|
||||
|
||||
.latest-thumb-left-skin ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 1), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.latest-thumb-left-skin ul {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 100);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 100);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 1열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 1;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 1;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-thumb-right-skin" style="<?php echo $css_vars; ?>">
|
||||
<!-- 표준 타이틀 영역 -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</li>
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul>
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<div class="lt_txt">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_content_is']) { ?>
|
||||
<p class="content"><?php echo cut_str(strip_tags($list[$i]['wr_content']), 100); ?></p>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="lt_img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Latest Thumb Right Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-thumb-right-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-thumb-right-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-thumb-right-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-thumb-right-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-thumb-right-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-thumb-right-skin .more_btn { position: relative; background: none; border: 1px solid #ddd; padding: 5px 10px; font-size: 12px; color: #666; cursor: pointer; border-radius: 3px; }
|
||||
.latest-thumb-right-skin .cb { display: none; }
|
||||
|
||||
.latest-thumb-right-skin ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 1), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.latest-thumb-right-skin ul {
|
||||
grid-template-columns: repeat(var(--mo-columns, 1), 1fr);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
include_once(G5_LIB_PATH.'/thumbnail.lib.php');
|
||||
|
||||
// 💡 [핵심] 라이브러리 함수를 사용하여 모듈 설정 로드
|
||||
$rb_skin = get_rb_module_config($options);
|
||||
|
||||
// 💡 [핵심] 설정값 적용 (없으면 기본값)
|
||||
$thumb_width = (int)($rb_skin['md_width'] ? $rb_skin['md_width'] : 200);
|
||||
$thumb_height = (int)($rb_skin['md_height'] ? $rb_skin['md_height'] : 150);
|
||||
$list_count = (is_array($list) && $list) ? count($list) : 0;
|
||||
|
||||
// 모듈 타이틀 설정
|
||||
if(isset($rb_skin['md_title']) && $rb_skin['md_title']) {
|
||||
$bo_subject = $rb_skin['md_title'];
|
||||
}
|
||||
|
||||
// 카테고리 링크 설정
|
||||
if(isset($rb_skin['md_sca']) && $rb_skin['md_sca']) {
|
||||
$links_url = get_pretty_url($bo_table,'','sca='.urlencode($rb_skin['md_sca']));
|
||||
} else {
|
||||
$links_url = get_pretty_url($bo_table);
|
||||
}
|
||||
|
||||
// 💡 [추가] CSS/JS 로드
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$latest_skin_url.'/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
if(file_exists($latest_skin_path.'/script.js')) {
|
||||
add_javascript('<script src="'.$latest_skin_url.'/script.js?ver='.G5_SERVER_TIME.'"></script>', 0);
|
||||
}
|
||||
|
||||
// 💡 [추가] 동적 그리드 변수 설정 (기본값 4열)
|
||||
$pc_columns = (isset($rb_skin['md_col']) && (int)$rb_skin['md_col'] > 0) ? (int)$rb_skin['md_col'] : 4;
|
||||
$mo_columns = (isset($rb_skin['md_col_mo']) && (int)$rb_skin['md_col_mo'] > 0) ? (int)$rb_skin['md_col_mo'] : 2;
|
||||
$css_vars = "--pc-columns: {$pc_columns}; --mo-columns: {$mo_columns};";
|
||||
|
||||
/*
|
||||
모듈설정 연동 변수
|
||||
... (주석 생략) ...
|
||||
*/
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo $latest_skin_url ?>/style.css?ver=<?php echo G5_SERVER_TIME ?>">
|
||||
<div class="latest-thumb-top-skin" style="<?php echo $css_vars; ?>">
|
||||
<!-- 표준 타이틀 영역 -->
|
||||
<ul class="bbs_main_wrap_tit" style="display:<?php echo (isset($rb_skin['md_title_hide']) && $rb_skin['md_title_hide'] == '1') ? 'none' : 'block'; ?>">
|
||||
<li class="bbs_main_wrap_tit_l">
|
||||
<a href="<?php echo $links_url; ?>">
|
||||
<h2 class="<?php echo isset($rb_skin['md_title_font']) ? $rb_skin['md_title_font'] : 'font-B'; ?>" style="color:<?php echo isset($rb_skin['md_title_color']) ? $rb_skin['md_title_color'] : '#25282b'; ?>; font-size:<?php echo isset($rb_skin['md_title_size']) ? $rb_skin['md_title_size'] : '20'; ?>px; "><?php echo $bo_subject ?></h2>
|
||||
</a>
|
||||
</li>
|
||||
<li class="bbs_main_wrap_tit_r">
|
||||
<button type="button" class="more_btn" onclick="location.href='<?php echo $links_url ?>';">더보기</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul>
|
||||
<?php
|
||||
for ($i=0; $i<$list_count; $i++) {
|
||||
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $list[$i]['href'] ?>">
|
||||
<?php if ($rb_skin['md_thumb_is']) { ?>
|
||||
<div class="lt_img">
|
||||
<?php if($thumb['src']) { ?>
|
||||
<img src="<?php echo $thumb['src']; ?>" alt="<?php echo $thumb['alt']; ?>">
|
||||
<?php } else { ?>
|
||||
<span class="no-img"></span>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<div class="lt_txt">
|
||||
<span class="subject"><?php echo $list[$i]['subject']; ?></span>
|
||||
<?php if ($rb_skin['md_content_is']) { ?>
|
||||
<p class="content"><?php echo cut_str(strip_tags($list[$i]['wr_content']), 100); ?></p>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php if ($list_count == 0) { ?>
|
||||
<li class="empty_li">게시물이 없습니다.</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Latest Thumb Top Skin Style - Final Layout Fix */
|
||||
|
||||
.latest-thumb-top-skin {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.latest-thumb-top-skin .bbs_main_wrap_tit {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #333;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.latest-thumb-top-skin .bbs_main_wrap_tit_l { min-width: 0; }
|
||||
.latest-thumb-top-skin .bbs_main_wrap_tit_l h2 { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.latest-thumb-top-skin .bbs_main_wrap_tit_r { flex-shrink: 0; margin-left: 15px; }
|
||||
.latest-thumb-top-skin .more_btn { position: relative; background: none; border: 1px solid #ddd; padding: 5px 10px; font-size: 12px; color: #666; cursor: pointer; border-radius: 3px; }
|
||||
.latest-thumb-top-skin .cb { display: none; }
|
||||
|
||||
.latest-thumb-top-skin ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(var(--pc-columns, 4), 1fr);
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.latest-thumb-top-skin ul {
|
||||
grid-template-columns: repeat(var(--mo-columns, 2), 1fr);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user