first commit 2
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit;
|
||||
|
||||
/**
|
||||
* laser.TLRB 레이아웃 설정 파일
|
||||
* 각 영역(Row)별로 가로 칸(Column) 개수를 설정합니다.
|
||||
*/
|
||||
|
||||
$layout_grid_config = [
|
||||
// '영역ID' => 칸 개수
|
||||
'top' => 1, // main-content-top (1칸: 100%)
|
||||
'middle' => 2, // main-content-middle (2칸: 50% / 50%)
|
||||
'middle1' => 1, // main-content-middle1 (1칸: 100%)
|
||||
'bottom' => 3, // main-content-bottom (3칸: 33% / 33% / 33%)
|
||||
'bottom1' => 1, // main-content-bottom (1칸: 100%)
|
||||
'left_ad' => false,
|
||||
'right_ad' => false,
|
||||
// 필요하다면 아래처럼 추가 가능
|
||||
// 'extra' => 4, // main-content-extra (4칸)
|
||||
];
|
||||
?>
|
||||
@@ -0,0 +1,83 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// 이 레이아웃 전용 CSS 파일을 불러옵니다.
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_THEME_URL.'/shop/rb.layout/laser.TLRB/style.css?ver='.G5_SERVER_TIME.'">', 0);
|
||||
|
||||
// 💡 [핵심] 설정 파일 로드
|
||||
$config_path = __DIR__ . '/config.php';
|
||||
if (file_exists($config_path)) {
|
||||
include_once($config_path);
|
||||
} else {
|
||||
// 설정 파일이 없을 경우 기본값
|
||||
$layout_grid_config = [
|
||||
'top' => 1,
|
||||
'middle' => 1,
|
||||
'bottom' => 1,
|
||||
'left_ad' => false,
|
||||
'right_ad' => false,
|
||||
];
|
||||
}
|
||||
?>
|
||||
|
||||
<!-- 💡 [추가] 메인 비주얼 섹션 시작 -->
|
||||
<div class="main-visual-section">
|
||||
<div class="main-visual-bg"></div>
|
||||
<div class="main-visual-content container">
|
||||
<h1 class="main-visual-title">공간을 완성하는 단 하나의 디테일</h1>
|
||||
<p class="main-visual-subtitle">최고급 자재와 장인의 기술로 탄생한 프리미엄 도어를 만나보세요.</p>
|
||||
<a href="<?php echo G5_SHOP_URL; ?>/list.php?ca_id=10" class="main-visual-button">전체 상품 보기</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 메인 비주얼 섹션 끝 -->
|
||||
|
||||
<div class="main-content-wrapper">
|
||||
<div class="three-column-layout container">
|
||||
<?php if ($layout_grid_config['left_ad']===true): ?>
|
||||
<!-- 1. 좌측 사이드바 -->
|
||||
<aside class="layout-sidebar-left">
|
||||
<div class="sidebar-inner">
|
||||
<?php if($is_admin) { ?> <h3 class="sidebar-title">광고 영역</h3> <?php } ?>
|
||||
<!-- 💡 [수정] 좌측 모듈 영역에 고유 ID 부여 -->
|
||||
<div class="flex_box flex_box_l" data-layout="main-left"></div>
|
||||
</div>
|
||||
</aside>
|
||||
<?php endif; ?>
|
||||
<!-- Rebuilder 시스템의 메인 콘텐츠 영역 -->
|
||||
<main class="layout-main-content">
|
||||
|
||||
<?php foreach ($layout_grid_config as $row_name => $columns): ?>
|
||||
<!-- 행(Row) 시작 -->
|
||||
<div class="layout-row layout-row-<?php echo $row_name; ?>" data-columns="<?php echo $columns; ?>">
|
||||
|
||||
<?php if ($columns == 1): ?>
|
||||
<!-- 1칸일 경우: 기존 ID 그대로 사용 (호환성 유지) -->
|
||||
<div class="flex_box layout-col" data-layout="main-content-<?php echo $row_name; ?>">
|
||||
<!-- --><?php //echo rb_get_modules('main-content-'.$row_name); ?>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<!-- 2칸 이상일 경우: 번호를 붙여서 분할 -->
|
||||
<?php for ($i = 1; $i <= $columns; $i++): ?>
|
||||
<div class="flex_box layout-col" data-layout="main-content-<?php echo $row_name; ?>-<?php echo $i; ?>">
|
||||
<!-- --><?php //echo rb_get_modules('main-content-'.$row_name.'-'.$i); ?>
|
||||
</div>
|
||||
<?php endfor; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
<!-- 행(Row) 끝 -->
|
||||
<?php endforeach; ?>
|
||||
|
||||
</main>
|
||||
<!-- 3. 우측 사이드바 -->
|
||||
<?php if ($layout_grid_config['right_ad']===true): ?>
|
||||
<aside class="layout-sidebar-right">
|
||||
<div class="sidebar-inner">
|
||||
<?php if($is_admin) { ?> <h3 class="sidebar-title">광고 영역</h3> <?php } ?>
|
||||
<!-- 💡 [수정] 우측 모듈 영역에 고유 ID 부여 -->
|
||||
<div class="flex_box flex_box_r" data-layout="main-right"></div>
|
||||
</div>
|
||||
</aside>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,107 @@
|
||||
/* laser.TLRB Layout Style - Dynamic Grid */
|
||||
|
||||
.layout-main-content {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* 행(Row) 스타일 */
|
||||
.layout-row {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
margin-bottom: 20px; /* 행 사이 간격 */
|
||||
gap: 20px; /* 열 사이 간격 */
|
||||
}
|
||||
|
||||
.layout-row:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
/* 열(Column) 스타일 */
|
||||
.layout-col {
|
||||
flex: 1; /* 남은 공간을 균등하게 차지 */
|
||||
min-width: 0; /* 내용물이 넘쳐도 레이아웃 깨짐 방지 */
|
||||
}
|
||||
|
||||
/* 💡 [추가] 메인 비주얼 섹션 스타일 */
|
||||
.main-visual-section {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 500px; /* 비주얼 영역 높이 */
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
text-align: center;
|
||||
color: #fff;
|
||||
margin-bottom: 60px; /* 메인 콘텐츠와의 간격 */
|
||||
}
|
||||
|
||||
.main-visual-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-image: url('https://images.unsplash.com/photo-1588854337236-6889d631f3e7?q=80&w=2070&auto=format&fit=crop'); /* 임시 배경 이미지 */
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
filter: brightness(0.5); /* 배경을 어둡게 처리하여 텍스트 가독성 확보 */
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.main-visual-content {
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.main-visual-title {
|
||||
font-size: 3rem;
|
||||
font-weight: 700;
|
||||
margin: 0 0 10px;
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.main-visual-subtitle {
|
||||
font-size: 1.2rem;
|
||||
margin: 0 0 30px;
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
.main-visual-button {
|
||||
display: inline-block;
|
||||
padding: 12px 30px;
|
||||
background-color: #ff3061; /* 포인트 색상 */
|
||||
color: #fff;
|
||||
text-decoration: none;
|
||||
font-weight: 700;
|
||||
border-radius: 4px;
|
||||
transition: background-color 0.3s ease;
|
||||
}
|
||||
|
||||
.main-visual-button:hover {
|
||||
background-color: #e02051; /* 호버 시 약간 더 어둡게 */
|
||||
}
|
||||
|
||||
|
||||
/* 모바일 반응형 */
|
||||
@media (max-width: 1024px) {
|
||||
.layout-row {
|
||||
flex-direction: column; /* 모바일에서는 세로로 쌓임 */
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.layout-col {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* 💡 [추가] 모바일용 메인 비주얼 스타일 */
|
||||
.main-visual-section {
|
||||
height: 400px;
|
||||
}
|
||||
.main-visual-title {
|
||||
font-size: 2.2rem;
|
||||
}
|
||||
.main-visual-subtitle {
|
||||
font-size: 1rem;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user