From 82fb418b7891af210d27d57d3f6e6b2a056134d6 Mon Sep 17 00:00:00 2001 From: TeddyElectronics Date: Mon, 23 Dec 2024 15:47:39 +0900 Subject: [PATCH] Update load_experiences.js --- assets/js/load_experiences.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/assets/js/load_experiences.js b/assets/js/load_experiences.js index c7b68d5..c7bf238 100644 --- a/assets/js/load_experiences.js +++ b/assets/js/load_experiences.js @@ -5,7 +5,7 @@ document.addEventListener('DOMContentLoaded', () => { .then(yamlText => { const experiencesData = jsyaml.load(yamlText); // YAML 파싱 const experienceContainer = document.querySelector('.experience-container'); - + if (experiencesData.experiences) { experiencesData.experiences.forEach(experienceGroup => { experienceGroup.positions.forEach(position => { @@ -19,7 +19,7 @@ document.addEventListener('DOMContentLoaded', () => { position.responsibilities.forEach(responsibility => { const listItem = document.createElement('li'); - // 수상 내역 중 강조 부분만 로 감싸기 + // 수상 내역에서 이모티콘과 텍스트 분리 및 처리 const match = responsibility.match(/(.*? - )(.*?)(🏆|🥇|🥈|🥉|🎖️|✨)(.*)/); if (match) { const textPart1 = document.createTextNode(match[1]); @@ -32,7 +32,8 @@ document.addEventListener('DOMContentLoaded', () => { listItem.appendChild(emoji); listItem.appendChild(textPart2); } else { - listItem.textContent = responsibility; // 매칭 실패 시 전체 텍스트 출력 + // 매칭 실패 시 전체 텍스트를 표시 + listItem.textContent = responsibility; } awardList.appendChild(listItem);