commit 4a304e5e0a1a1a98723cc3fb21c53d73f4283598 Author: Mas Budi Kusuma Date: Tue Sep 15 20:50:26 2026 +0700 chore: inisialisasi repo tema edukarsa diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a62d321 --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +.DS_Store +Thumbs.db +*.log +.vscode/ +.idea/ diff --git a/footer.php b/footer.php new file mode 100644 index 0000000..7eafe34 --- /dev/null +++ b/footer.php @@ -0,0 +1,65 @@ + +
+
+ Kemdikbud +
+
+ + + + + + + \ No newline at end of file diff --git a/front-page.php b/front-page.php new file mode 100644 index 0000000..f1d55d6 --- /dev/null +++ b/front-page.php @@ -0,0 +1,271 @@ + + +
+ + + +
+
+ 'slider', 'posts_per_page' => -1 ) ); + if ( $query_slider->have_posts() ) : + echo '
'; + while ( $query_slider->have_posts() ) : $query_slider->the_post(); + $link = get_post_meta( get_the_ID(), '_slider_link', true ); + ?> +
+ '; ?> + + + +
๐Ÿ–ผ๏ธUpload Gambar Slider untuk ""
+ + '; ?> +
+ '; + wp_reset_postdata(); + endif; + ?> +
+
+ + + + +
+
+ +
+
+ + + Icon + + ๐Ÿซ + +
+

+

+

+
+ +
+
+ + + + +
+
+
+
+ + + Kepala Sekolah + +
๐Ÿ‘คUpload Foto Kepala Sekolah
+ +
+
+
+ ABOUT US +

+

+
+ Ketahui Lebih Lanjut +
+
+
+ + + + +
+
+ 'milestone', 'posts_per_page' => 4 ) ); + if ( $query_milestone->have_posts() ) : + while ( $query_milestone->have_posts() ) : $query_milestone->the_post(); + echo '

' . get_the_title() . '

' . get_the_excerpt() . '
'; + endwhile; + wp_reset_postdata(); + endif; + ?> +
+
+ + + + +
+
+

Our Program


+
+ 'program', 'posts_per_page' => 3 ) ); + if ( $query_program->have_posts() ) : + while ( $query_program->have_posts() ) : $query_program->the_post(); + ?> +
+
+ + + +
๐ŸซGambar Program
+ +
+

+
+ Lihat Detail +
+ +
+
+
+ + + + +
+
+ + + + + + +
+
+
+ +

+
+
+ 'keunggulan', 'posts_per_page' => 9 ) ); + if ( $query_keunggulan->have_posts() ) : + $nomor = 1; + while ( $query_keunggulan->have_posts() ) : $query_keunggulan->the_post(); + ?> +
+
+
+

+
+ +
+
+
+ +
+
+
+ + +
+ + + + + +
> +
+

+ + + +
+
+ + + + +
+
+
+

+
+
+ 'post', 'posts_per_page' => 6) ); + if ( $query_news->have_posts() ) : + while ( $query_news->have_posts() ) : $query_news->the_post(); + ?> +
+
+ + + +
๐Ÿ“ฐGambar Berita
+ +
+
+

+
+ Read More +
+
+ +
+
+
+ + +
+ + + + \ No newline at end of file diff --git a/functions.php b/functions.php new file mode 100644 index 0000000..10cb27a --- /dev/null +++ b/functions.php @@ -0,0 +1,15 @@ + +> + + + + + +> + + \ No newline at end of file diff --git a/inc/admin-menu.php b/inc/admin-menu.php new file mode 100644 index 0000000..4a6cd7d --- /dev/null +++ b/inc/admin-menu.php @@ -0,0 +1,176 @@ +

EduKarsa Dashboard

Gunakan Pengaturan Utama untuk memodifikasi Halaman Depan.

'; +} + +function edukarsa_settings_page_html() { + if ( ! current_user_can( 'manage_options' ) ) return; + ?> + + +
+

Pengaturan EduKarsa Lengkap

+ +
+ + +
+

1. Header, Logo & Slider

+ + +
Logo Website
+
+
/>
+
/>
+ + + + + + + +
Statistik + Ikon:
+ Angka:
+ Judul:
+ Subteks: +
+
+ +
+

2. Tentang Kami

+
/>
+ + + + + + +
Foto
Nama
Sub-Judul
Teks
Link
+
+ +
+

3. Program, Milestones, & Keunggulan

+
/>
+
/>
+
+
/>
+ + + +
Subtitle (Contoh: WHY CHOOSE US)
Judul (Contoh: Keunggulan Program)
+
+ +
+

4. Video & Latar Parallax (Area Biru Tengah)

+ + + +
Gambar Parallax
Warna Overlay Parallax
+
+
/>
+ + + +
Video 1Thumb:
URL:
Video 2Thumb:
URL:
+
+ +
+

5. CTA, Berita, Footer & Sosial Media

+
/>
+ + + + +
Gambar Bg
Judul
TombolTeks:
URL:
+
+
/>
+ + +
Judul Seksi Berita
+ +

Footer

+ + + + + +
Alamat
Telepon
Email
Copyright
+ +

Sosial Media

+ + + + +
Facebook> Aktifkan  |  URL:
Instagram> Aktifkan  |  URL:
YouTube> Aktifkan  |  URL:
+
+ +

+
+
+ + + array('name' => 'Semua Slider', 'singular_name' => 'Slider', 'add_new_item' => 'Tambah Slider'), + 'supports' => array('title', 'thumbnail'), 'public' => false, 'show_ui' => true, 'show_in_menu' => false + )); + register_post_type( 'program', array( + 'labels' => array('name' => 'Semua Program', 'singular_name' => 'Program', 'add_new_item' => 'Tambah Program'), + 'supports' => array('title', 'editor', 'thumbnail', 'excerpt'), 'public' => true, 'show_ui' => true, 'show_in_menu' => false + )); + register_post_type( 'milestone', array( + 'labels' => array('name' => 'Semua Milestone', 'singular_name' => 'Milestone', 'add_new_item' => 'Tambah Milestone'), + 'supports' => array('title', 'excerpt'), 'public' => false, 'show_ui' => true, 'show_in_menu' => false + )); + register_post_type( 'keunggulan', array( + 'labels' => array('name' => 'Semua Keunggulan', 'singular_name' => 'Keunggulan', 'add_new_item' => 'Tambah Keunggulan'), + 'supports' => array('title', 'editor'), 'public' => false, 'show_ui' => true, 'show_in_menu' => false + )); +} +add_action( 'init', 'edukarsa_register_all_cpt', 0 ); + +// --- METABOX UNTUK LINK SLIDER --- +function edukarsa_slider_meta_box() { + add_meta_box( 'slider_link_meta', 'Tautan (URL) Slider', 'edukarsa_slider_meta_callback', 'slider', 'normal', 'high' ); +} +add_action( 'add_meta_boxes', 'edukarsa_slider_meta_box' ); + +function edukarsa_slider_meta_callback( $post ) { + wp_nonce_field( 'edukarsa_slider_save', 'edukarsa_slider_meta_nonce' ); + $value = get_post_meta( $post->ID, '_slider_link', true ); + echo '

Masukkan URL tujuan jika pengunjung mengklik gambar slider ini (opsional).

'; + echo ''; +} + +function edukarsa_slider_save_meta( $post_id ) { + if ( ! isset( $_POST['edukarsa_slider_meta_nonce'] ) || ! wp_verify_nonce( $_POST['edukarsa_slider_meta_nonce'], 'edukarsa_slider_save' ) ) return; + if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return; + if ( isset( $_POST['slider_link'] ) ) { update_post_meta( $post_id, '_slider_link', sanitize_text_field( $_POST['slider_link'] ) ); } +} +add_action( 'save_post', 'edukarsa_slider_save_meta' ); \ No newline at end of file diff --git a/inc/setup.php b/inc/setup.php new file mode 100644 index 0000000..b713c49 --- /dev/null +++ b/inc/setup.php @@ -0,0 +1,41 @@ + __( 'Menu Utama', 'edukarsa' ), + 'menu-footer' => __( 'Menu Footer', 'edukarsa' ), + ) ); +} +add_action( 'after_setup_theme', 'edukarsa_setup' ); + +// 2. MENGHUBUNGKAN ASET (CSS & JS FRONTEND) +function edukarsa_scripts() { + // Memaksa path absolut langsung ke folder tema + wp_enqueue_style( + 'edukarsa-style', + get_template_directory_uri() . '/style.css', + array(), + time(), + 'all' + ); +} +add_action( 'wp_enqueue_scripts', 'edukarsa_scripts' ); + +// 3. MEMUAT JAVASCRIPT UNTUK MEDIA UPLOADER (DASHBOARD) +function edukarsa_admin_scripts( $hook ) { + // Memastikan skrip uploader dipanggil di halaman pengaturan Edukarsa[cite: 9] + if ( strpos( $hook, 'edukarsa' ) !== false ) { + wp_enqueue_media(); + } +} +add_action( 'admin_enqueue_scripts', 'edukarsa_admin_scripts' ); \ No newline at end of file diff --git a/index.php b/index.php new file mode 100644 index 0000000..7d79327 --- /dev/null +++ b/index.php @@ -0,0 +1,103 @@ + + +
+ + + +
+ + + +
+ + + + + + +
+

Belum Ada Berita

+

Maaf, saat ini belum ada artikel, berita, atau pengumuman yang dipublikasikan.

+
+ + +
+ + \ No newline at end of file diff --git a/style.css b/style.css new file mode 100644 index 0000000..6813074 --- /dev/null +++ b/style.css @@ -0,0 +1,169 @@ +/* +Theme Name: EduKarsa +Theme URI: https://edukarsa.masbudi.my.id +Author: masbudikusuma +Author URI: https://masbudi.my.id +Description: Tema WordPress profesional untuk sekolah (Gaya Modern Card Layout). +Version: 1.0.0 +*/ + + +:root { + --primary-color: #0b4a8e; + --secondary-color: #1a73e8; + --text-color: #4a4a4a; + --heading-color: #1a2b4c; + --bg-light-blue: #f0f7ff; + --bg-white: #ffffff; + --radius: 12px; + --shadow: 0 10px 30px rgba(0, 0, 0, 0.05); + --font-main: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; +} + +/* 1. RESET & DASAR */ +* { box-sizing: border-box; margin: 0; padding: 0; } +body { font-family: var(--font-main); color: var(--text-color); background-color: var(--bg-white); line-height: 1.6; font-size: 16px; } +img { max-width: 100%; height: auto; display: block; } +a { text-decoration: none; color: var(--primary-color); transition: 0.3s; } + +/* 2. LAYOUT KOTAK UTAMA */ +.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; } +.text-center { text-align: center; } +.text-white { color: #fff !important; } +.edukarsa-section { padding: 80px 0; } +.section-title { font-size: 32px; color: var(--heading-color); margin-bottom: 15px; font-weight: 800; } + +/* 3. HEADER & MENU NAVIGATION */ +.site-header { position: sticky; top: 0; z-index: 999; box-shadow: 0 4px 10px rgba(0,0,0,0.1); padding: 15px 0; } +.header-container { display: flex; justify-content: space-between; align-items: center; } +.logo-link { display: flex; align-items: center; gap: 15px; color: #fff; } +.site-title { margin: 0; font-size: 24px; font-weight: 800; color: #fff; } +.nav-menu-custom { list-style: none; display: flex; gap: 25px; margin: 0; padding: 0; } +.nav-menu-custom li a { display: block; color: #ffffff; font-weight: 600; font-size: 16px; text-transform: uppercase; letter-spacing: 0.5px; padding: 10px 0; } +.nav-menu-custom li a:hover { color: #f39c12; } + +/* 3.1 DROPDOWN MENU (Sub-menu Animasi) */ +.nav-menu-custom li { position: relative; } /* Agar sub-menu mengikuti induknya */ +.nav-menu-custom .sub-menu { + position: absolute; + top: 100%; /* Turun di bawah menu utama */ + left: 0; + background-color: var(--primary-color); + min-width: 220px; + padding: 10px 0; + border-radius: 0 0 8px 8px; + box-shadow: 0 10px 25px rgba(0,0,0,0.2); + opacity: 0; + visibility: hidden; /* Sembunyikan secara default */ + transform: translateY(15px); /* Posisi awal agak ke bawah */ + transition: all 0.3s ease; + z-index: 1000; +} +.nav-menu-custom li:hover > .sub-menu { + opacity: 1; + visibility: visible; + transform: translateY(0); /* Muncul dengan mulus ke atas */ +} +.nav-menu-custom .sub-menu li a { + padding: 10px 20px; + font-size: 14px; + text-transform: none; /* Sub menu tidak kapital semua */ + border-bottom: 1px solid rgba(255,255,255,0.05); +} +.nav-menu-custom .sub-menu li:last-child a { border-bottom: none; } +/* Sub-menu di dalam sub-menu (Level 3) */ +.nav-menu-custom .sub-menu .sub-menu { top: 0; left: 100%; transform: translateX(15px); } +.nav-menu-custom .sub-menu li:hover > .sub-menu { transform: translateX(0); } + +/* 4. ANIMASI SLIDER */ +.edukarsa-hero-slider { padding: 0; } +.slider-container { position: relative; width: 100%; overflow: hidden; } +.slider-wrapper { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -ms-overflow-style: none; scroll-behavior: smooth; } +.slider-wrapper::-webkit-scrollbar { display: none; } +.slide-item { flex: 0 0 100%; position: relative; scroll-snap-align: center; } + +/* 5. KOMPONEN UMUM */ +.bg-light-blue { background-color: var(--bg-light-blue); } +.bg-dark-blue { background-color: var(--primary-color); } +.card-style { background: var(--bg-white); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid rgba(0,0,0,0.03); transition: transform 0.3s ease; } +.card-style:hover { transform: translateY(-5px); } +.top-border-blue { border-top: 4px solid var(--primary-color); } +.title-underline { width: 50px; border: 2px solid #f39c12; margin: 10px auto 30px; } + +/* BUTTONS */ +.btn-primary { display: inline-block; background-color: var(--primary-color); color: var(--bg-white); padding: 12px 35px; border-radius: 50px; font-weight: bold; letter-spacing: 0.5px; } +.btn-primary:hover { background-color: var(--secondary-color); color: #fff; } +.btn-light { background-color: #fff; color: var(--primary-color); } +.btn-light:hover { background-color: #f1f1f1; color: var(--primary-color); } +.btn-outline-primary { display: inline-block; border: 2px solid var(--primary-color); color: var(--primary-color); padding: 8px 20px; border-radius: 50px; font-size: 14px; font-weight: bold; } +.btn-outline-primary:hover { background-color: var(--primary-color); color: #fff; } +.badge-title { display: inline-block; color: var(--secondary-color); font-weight: 700; font-size: 14px; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 10px; } + +/* 6. GRID SYSTEM (Stats, Milestones, Program, Video, Keunggulan, News) */ +.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; position: relative; z-index: 10; margin-top: -80px; margin-bottom: 40px; } +.stat-card-modern { padding: 40px 30px; text-align: left; border-radius: 24px; border-top: 5px solid var(--secondary-color); transition: all 0.3s ease; background: #fff; } +.stat-card-modern:hover { transform: translateY(-8px); box-shadow: 0 20px 40px rgba(11, 74, 142, 0.12); } +.stat-icon-wrapper { width: 65px; height: 65px; background-color: #e6f0fa; border-radius: 18px; display: flex; align-items: center; justify-content: center; margin-bottom: 25px; font-size: 28px; } +.stat-icon-wrapper img { width: 32px; height: 32px; object-fit: contain; } +.stat-card-modern .stat-number { font-size: 46px; font-weight: 900; color: var(--primary-color); margin-bottom: 5px; line-height: 1; } +.stat-card-modern .stat-title { font-size: 18px; font-weight: 800; color: var(--heading-color); margin-bottom: 8px; } +.stat-card-modern .stat-desc { font-size: 14px; color: #64748b; line-height: 1.6; margin: 0; } +.pt-0 { padding-top: 20px !important; } + +.sambutan-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 60px; align-items: center; } +.sambutan-text { color: #666; font-size: 16px; margin-bottom: 30px; } +.milestone-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; } +.milestone-item { padding: 20px; } +.program-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; } +.program-card { padding: 40px 20px; } +.video-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px; padding: 40px 0; } +.video-item { position: relative; border-radius: var(--radius); overflow: hidden; border: 5px solid rgba(255,255,255,0.2); } +.play-btn { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); background: #e74c3c; color: white; padding: 20px; border-radius: 50%; font-size: 24px; cursor: pointer; } + +/* EFEK PARALLAX (AREA BIRU) */ +.parallax-section-wrapper { position: relative; background-attachment: fixed; background-position: center; background-repeat: no-repeat; background-size: cover; } +.parallax-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; z-index: 1; } +.relative-z2 { position: relative; z-index: 2; } + +.keunggulan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 30px; } +.keunggulan-card { position: relative; padding: 30px; display: flex; align-items: flex-start; overflow: hidden; } +.keunggulan-number { position: absolute; top: 10px; right: 10px; font-size: 80px; font-weight: 900; color: rgba(11, 74, 142, 0.05); line-height: 1; z-index: 0; } +.keunggulan-content-inner { position: relative; z-index: 1; } +.keunggulan-content-inner h4 { color: var(--primary-color); margin-bottom: 10px; font-size: 18px;} + +.edukarsa-cta-bg { background-size: cover; background-position: center; position: relative; padding: 100px 0; } +.edukarsa-cta-bg::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(11, 74, 142, 0.85); z-index: 1;} +.edukarsa-cta-bg .container { position: relative; z-index: 2; } + +.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; } +.news-content { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; } +.news-title { font-size: 18px; margin-bottom: 10px; line-height: 1.4; } + +/* 7. IMAGE LOCKS & PLACEHOLDERS */ +.img-wrapper-slider { height: 600px; width: 100%; overflow: hidden; position: relative; } +.img-wrapper-landscape { aspect-ratio: 4/3; width: 100%; overflow: hidden; position: relative; border-radius: 8px; } +.img-wrapper-video { aspect-ratio: 16/9; width: 100%; overflow: hidden; position: relative; border-radius: 12px; } +.img-wrapper-portrait { aspect-ratio: 3/4; width: 100%; max-width: 350px; overflow: hidden; position: relative; border-radius: 12px; box-shadow: var(--shadow); } +.img-wrapper-slider img, .img-wrapper-landscape img, .img-wrapper-video img, .img-wrapper-portrait img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; } +.img-placeholder { width: 100%; height: 100%; background-color: #f1f5f9; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #94a3b8; font-size: 14px; text-align: center; border: 2px dashed #cbd5e1; } +.img-placeholder i { font-size: 32px; margin-bottom: 5px; font-style: normal; opacity: 0.5; } + +/* 8. FOOTER STYLING */ +.footer-links-custom { list-style: none; padding: 0; margin: 0; line-height: 2; } +.footer-links-custom li a { color: #ffffff; opacity: 0.8; } +.footer-links-custom li a:hover { opacity: 1; color: #f39c12; } + +/* 9. RESPONSIVE MEDIA QUERIES */ +@media (max-width: 992px) { + .keunggulan-grid, .program-grid, .milestone-grid, .news-grid { grid-template-columns: repeat(2, 1fr); } + .video-grid { grid-template-columns: 1fr; } + .sambutan-grid { grid-template-columns: 1fr; } +} +@media (max-width: 768px) { + .header-container { flex-direction: column; gap: 15px; } + .nav-menu-custom { flex-wrap: wrap; justify-content: center; } + .nav-menu-custom .sub-menu { position: static; visibility: visible; opacity: 1; transform: none; box-shadow: none; background: rgba(0,0,0,0.1); } + .keunggulan-grid, .program-grid, .milestone-grid, .stats-grid, .news-grid { grid-template-columns: 1fr; } + .edukarsa-stats { margin-top: -40px; } + .img-wrapper-slider { height: 400px; } +} \ No newline at end of file