{"id":361,"date":"2024-08-29T23:54:48","date_gmt":"2024-08-29T14:54:48","guid":{"rendered":"http:\/\/www.wp.ainiigata.com\/?p=361"},"modified":"2024-08-30T00:11:11","modified_gmt":"2024-08-29T15:11:11","slug":"361","status":"publish","type":"post","link":"https:\/\/www.wp.ainiigata.com\/?p=361","title":{"rendered":"\u8996\u529b\u691c\u67fb\u30a2\u30d7\u30ea"},"content":{"rendered":"\n<!DOCTYPE html>\n<html lang=\"ja\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>\u8996\u529b\u691c\u67fb<\/title>\n    <style>\n        body {\n            font-family: Arial, sans-serif;\n            text-align: center;\n            margin-top: 20px;\n        }\n        #landolt {\n            display: inline-block;\n        }\n        img {\n            width: auto;\n            height: auto;\n            max-width: 100%;\n            max-height: 100%;\n            object-fit: contain;\n        }\n        button, input, select {\n            padding: 10px 20px;\n            margin: 10px;\n            font-size: 18px;\n        }\n        #controls {\n            margin-top: 20px;\n        }\n        #settings {\n            margin-bottom: 20px;\n        }\n        #message {\n            color: red;\n            font-weight: bold;\n        }\n        .result-item {\n            margin: 5px 0;\n        }\n        #history {\n            margin-top: 20px;\n        }\n        table {\n            width: 60%; \/* \u8868\u306e\u5e45\u3092\u7e2e\u5c0f *\/\n            margin: 0 auto; \/* \u8868\u3092\u4e2d\u592e\u306b\u914d\u7f6e *\/\n            border-collapse: collapse;\n        }\n        th, td {\n            border: 1px solid #ddd;\n            padding: 8px;\n            text-align: left;\n        }\n        th {\n            background-color: #f2f2f2;\n        }\n        th:nth-child(1), td:nth-child(1) {\n            width: 5cm; \/* \u691c\u67fb\u6761\u4ef6\u306e\u5217\u30925cm\u306b\u8a2d\u5b9a *\/\n        }\n        th:nth-child(2), td:nth-child(2) {\n            width: 2cm; \/* \u691c\u67fb\u3057\u305f\u76ee\u306e\u5217\u30922cm\u306b\u8a2d\u5b9a *\/\n        }\n        th:nth-child(3), td:nth-child(3) {\n            width: 2cm; \/* \u8996\u529b\u306e\u5217\u30922cm\u306b\u8a2d\u5b9a *\/\n        }\n        \n    <\/style>\n<\/head>\n<body>\n    <h1>\u8996\u529b\u691c\u67fb<\/h1>\n    <div id=\"scale-container\">\n        <br>\n        <div id=\"scale\"><\/div>\n        <div id=\"scale-label\">\u300c\u2015\u2015\u2015\u2015\u300d\u5de6\u306e\u7dda\u304c\u7d04\uff11cm\u306b\u306a\u308b\u3088\u3046\u306b\u753b\u9762\u30b5\u30a4\u30ba\u3092\u8abf\u6574\u3057\u3066\u304f\u3060\u3055\u3044<\/div>\n    <\/div>\n    <br>\n    <br>\n    <p>\u4f7f\u7528\u65b9\u6cd5:<\/p>\n    <p>1. \u753b\u9762\u304b\u3089\u306e\u8ddd\u96e2\uff08\u56fa\u5b9a: 50cm\uff09\u3092\u78ba\u8a8d\u3057\u3001\u6e2c\u5b9a\u6761\u4ef6\u3068\u6e2c\u5b9a\u3059\u308b\u76ee\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n    <p>2. \u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u306e\u65b9\u5411\u3092\u30ad\u30fc\u30dc\u30fc\u30c9\u306e\u77e2\u5370\u30ad\u30fc\uff08\u4e0a\u3001\u4e0b\u3001\u5de6\u3001\u53f3\uff09\u307e\u305f\u306f\u753b\u9762\u306e\u30dc\u30bf\u30f3\u3067\u9078\u629e\u3057\u307e\u3059\u3002<\/p>\n    <p>3. \u6b63\u3057\u3044\u65b9\u5411\u3092\u9078\u3076\u3068\u8996\u529b\u30ec\u30d9\u30eb\u304c\u4e0a\u304c\u308a\u3001\u9593\u9055\u3048\u308b\u3068\u691c\u67fb\u7d42\u4e86\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n    <p>4. \u7d9a\u3051\u3066\u691c\u67fb\u3057\u305f\u5834\u5408\u306f\u6e2c\u5b9a\u6761\u4ef6\u3092\u5909\u66f4\u3057\u3066\u304b\u3089\u300c\u6b21\u306e\u691c\u67fb\u3078\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n    <p>5. \u300c\u3059\u3079\u3066\u521d\u671f\u5316\u3059\u308b\u300d\u3092\u30af\u30ea\u30c3\u30af\u3059\u308b\u3068\u3001\u5168\u3066\u306e\u8a2d\u5b9a\u3068\u5c65\u6b74\u304c\u30ea\u30bb\u30c3\u30c8\u3055\u308c\u307e\u3059\u3002<\/p>\n\n    <div id=\"settings\">\n        <p>\u6e2c\u5b9a\u6761\u4ef6\u3092\u8a2d\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044:<\/p>\n        <label for=\"eyeCondition\">\u88f8\u773c\u30fb\u773c\u93e1\u30fb\u30b3\u30f3\u30bf\u30af\u30c8:<\/label>\n        <select id=\"eyeCondition\" onchange=\"updateEyeCondition()\">\n            <option value=\"\u88f8\u773c\">\u88f8\u773c<\/option>\n            <option value=\"\u773c\u93e1\">\u773c\u93e1\u30fb\u30b3\u30f3\u30bf\u30af\u30c8\u4f7f\u7528<\/option>\n        <\/select>\n        <br>\n        <label for=\"eyeSide\">\u3069\u306e\u76ee\u3067\u6e2c\u5b9a\u3057\u307e\u3059\u304b:<\/label>\n        <select id=\"eyeSide\">\n            <option value=\"\u53f3\u76ee\">\u53f3\u76ee<\/option>\n            <option value=\"\u5de6\u76ee\">\u5de6\u76ee<\/option>\n            <option value=\"\u4e21\u76ee\">\u4e21\u76ee<\/option>\n        <\/select>\n    <\/div>\n\n    <div id=\"landolt\">\n        <img decoding=\"async\" id=\"landoltImage\" src=\"\" alt=\"\u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\">\n    <\/div>\n\n    <div id=\"controls\">\n        <button onclick=\"checkAnswer('up')\">\u4e0a<\/button>\n        <button onclick=\"checkAnswer('down')\">\u4e0b<\/button>\n        <button onclick=\"checkAnswer('left')\">\u5de6<\/button>\n        <button onclick=\"checkAnswer('right')\">\u53f3<\/button>\n        <button onclick=\"resetAll()\">\u3059\u3079\u3066\u521d\u671f\u5316\u3059\u308b<\/button>\n        <button onclick=\"nextTest()\">\u6b21\u306e\u691c\u67fb\u3078<\/button>\n    <\/div>\n\n    <p id=\"message\"><\/p>\n\n    <div id=\"history\">\n        <h2>\u691c\u67fb\u5c65\u6b74<\/h2>\n        <table>\n            <thead>\n                <tr>\n                    <th>\u691c\u67fb\u6761\u4ef6<\/th>\n                    <th>\u691c\u67fb\u3057\u305f\u76ee<\/th>\n                    <th>\u8996\u529b<\/th>\n                <\/tr>\n            <\/thead>\n            <tbody id=\"historyTable\">\n                <!-- \u691c\u67fb\u5c65\u6b74\u304c\u3053\u3053\u306b\u8868\u793a\u3055\u308c\u307e\u3059 -->\n            <\/tbody>\n        <\/table>\n    <\/div>\n\n    <script>\n        const images = {\n            up: \"https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u753b\u50cf\uff12-3-e1724552487767.png\",\n            down: \"https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u753b\u50cf\uff12-1-e1724552466948.png\",\n            left: \"https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u753b\u50cf\uff12.png\",\n            right: \"https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u753b\u50cf\uff12-2-e1724552479448.png\"\n        };\n\n        const visionLevels = {\n            \"0.1\": 50,\n            \"0.2\": 25,\n            \"0.3\": 16.7,\n            \"0.4\": 12.5,\n            \"0.5\": 10,\n            \"0.6\": 8.3,\n            \"0.7\": 7.1,\n            \"0.8\": 6.25,\n            \"0.9\": 5.6,\n            \"1.0\": 5\n        };\n\n        let directions = ['up', 'down', 'left', 'right'];\n        let currentDirection = '';\n        let currentVisionLevel = 0.1;\n        let results = { '\u53f3\u76ee': null, '\u5de6\u76ee': null, '\u4e21\u76ee': null };\n        let testCount = 0;\n        let testActive = true;  \/\/ \u30c6\u30b9\u30c8\u306e\u30a2\u30af\u30c6\u30a3\u30d6\u72b6\u614b\u3092\u7ba1\u7406\u3059\u308b\u30d5\u30e9\u30b0\n        let history = [];  \/\/ \u691c\u67fb\u5c65\u6b74\u3092\u7ba1\u7406\u3059\u308b\u914d\u5217\n\n        function updateEyeCondition() {\n            \/\/ \u73fe\u5728\u306e\u691c\u67fb\u6761\u4ef6\u3092\u66f4\u65b0\u3059\u308b\u305f\u3081\u306e\u7a7a\u306e\u95a2\u6570\n        }\n\n        function startTest() {\n            if (!testActive) return; \/\/ \u30c6\u30b9\u30c8\u304c\u7121\u52b9\u306a\u5834\u5408\u306f\u4f55\u3082\u3057\u306a\u3044\n\n            currentDirection = directions[Math.floor(Math.random() * directions.length)];\n            const distance = 50; \/\/ \u56fa\u5b9a\u8ddd\u96e250cm\n            const ringSize = visionLevels[currentVisionLevel.toFixed(1)];\n            const size = ringSize * (distance \/ 50);  \/\/ \u8ddd\u96e2\u306b\u5fdc\u3058\u3066\u30b5\u30a4\u30ba\u3092\u8abf\u6574\n            document.getElementById('landoltImage').src = images[currentDirection];\n            document.getElementById('landoltImage').style.width = `${size}px`;\n            document.getElementById('landoltImage').style.height = `${size}px`;\n        }\n\n        function checkAnswer(answer) {\n            if (!testActive) return; \/\/ \u30c6\u30b9\u30c8\u304c\u7121\u52b9\u306a\u5834\u5408\u306f\u4f55\u3082\u3057\u306a\u3044\n\n            if (answer === currentDirection) {\n                document.getElementById('message').innerText = `\u6b63\u89e3\uff01\u8996\u529b ${currentVisionLevel.toFixed(1)} \u3092\u30af\u30ea\u30a2\u3057\u307e\u3057\u305f\u3002\u6b21\u306e\u30ec\u30d9\u30eb\u3078\u9032\u307f\u307e\u3059\u3002`;\n                if (currentVisionLevel < 1.0) {\n                    currentVisionLevel += 0.1;\n                }\n            } else {\n                const calculatedVision = currentVisionLevel.toFixed(1);\n                document.getElementById('message').innerText = `\u4e0d\u6b63\u89e3\u3002\u3042\u306a\u305f\u306e\u8996\u529b\u306f: ${calculatedVision}`;\n                recordResult(calculatedVision);\n                testActive = false; \/\/ \u4e0d\u6b63\u89e3\u3067\u30c6\u30b9\u30c8\u3092\u7121\u52b9\u5316\n            }\n            startTest(); \/\/ \u6b21\u306e\u554f\u984c\u3092\u958b\u59cb\n        }\n\n        function recordResult(vision) {\n            const eyeSide = document.getElementById('eyeSide').value;\n            const eyeCondition = document.getElementById('eyeCondition').value === '\u773c\u93e1' ? '\u773c\u93e1\u30fb\u30b3\u30f3\u30bf\u30af\u30c8\u4f7f\u7528' : document.getElementById('eyeCondition').value;\n            results[eyeSide] = vision;\n            history.push({\n                eyeSide: eyeSide,\n                eyeCondition: eyeCondition,\n                vision: vision\n            });\n\n            \/\/ \u5c65\u6b74\u304c5\u4ef6\u3092\u8d85\u3048\u308b\u5834\u5408\u3001\u53e4\u3044\u5c65\u6b74\u3092\u524a\u9664\n            if (history.length > 5) {\n                history.shift();\n            }\n\n            updateHistoryTable();\n        }\n\n        function updateHistoryTable() {\n            const historyTable = document.getElementById('historyTable');\n            historyTable.innerHTML = '';\n            history.forEach(record => {\n                const row = document.createElement('tr');\n                row.innerHTML = `\n                    <td>${record.eyeCondition}<\/td>\n                    <td>${record.eyeSide}<\/td>\n                    <td>${record.vision}<\/td>\n                `;\n                historyTable.appendChild(row);\n            });\n        }\n\n        function resetAll() {\n            location.reload();  \/\/ \u30da\u30fc\u30b8\u3092\u30ea\u30ed\u30fc\u30c9\u3057\u3066\u5b8c\u5168\u306b\u521d\u671f\u5316\n        }\n\n        function nextTest() {\n            \/\/ \u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u306e\u30b5\u30a4\u30ba\u3092\u521d\u671f\u5316\u3057\u3001\u5c65\u6b74\u306f\u305d\u306e\u307e\u307e\u6b8b\u3059\n            currentVisionLevel = 0.1;\n            testActive = true; \/\/ \u30c6\u30b9\u30c8\u3092\u518d\u3073\u30a2\u30af\u30c6\u30a3\u30d6\u306b\u3059\u308b\n            document.getElementById('message').innerText = '';\n            startTest(); \/\/ \u30c6\u30b9\u30c8\u3092\u518d\u958b\n        }\n\n        \/\/ \u30ad\u30fc\u30dc\u30fc\u30c9\u5165\u529b\u3092\u51e6\u7406\n        document.addEventListener('keydown', (event) => {\n            if (event.key === 'ArrowUp') checkAnswer('up');\n            if (event.key === 'ArrowDown') checkAnswer('down');\n            if (event.key === 'ArrowLeft') checkAnswer('left');\n            if (event.key === 'ArrowRight') checkAnswer('right');\n        });\n\n        startTest();  \/\/ \u521d\u671f\u8a2d\u5b9a\u3067\u958b\u59cb\n    <\/script>\n<\/body>\n<\/html>\n\n","protected":false},"excerpt":{"rendered":"<p>\u8996\u529b\u691c\u67fb \u8996\u529b\u691c\u67fb \u300c\u2015\u2015\u2015\u2015\u300d\u5de6\u306e\u7dda\u304c\u7d04\uff11cm\u306b\u306a\u308b\u3088\u3046\u306b\u753b\u9762\u30b5\u30a4\u30ba\u3092\u8abf\u6574\u3057\u3066\u304f\u3060\u3055\u3044 \u4f7f\u7528\u65b9\u6cd5: 1. \u753b\u9762\u304b\u3089\u306e\u8ddd\u96e2\uff08\u56fa\u5b9a: 50cm\uff09\u3092\u78ba\u8a8d\u3057\u3001\u6e2c\u5b9a\u6761\u4ef6\u3068\u6e2c\u5b9a\u3059\u308b\u76ee\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 2. \u30e9\u30f3\u30c9\u30eb\u30c8\u74b0\u306e\u65b9\u5411\u3092<\/p>\n","protected":false},"author":1,"featured_media":358,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jin_ogp_image_url":"","_jin_last_featured_id":0,"footnotes":""},"categories":[3],"tags":[166,163,165,162,164],"class_list":["post-361","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-appplicaton","tag-166","tag-163","tag-165","tag-162","tag-164"],"rttpg_featured_image_url":{"full":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"landscape":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"portraits":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"thumbnail":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4-150x141.png",150,141,true],"medium":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"large":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"1536x1536":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"2048x2048":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"post-thumbnail":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4-150x141.png",150,141,true],"cps_thumbnails":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"small_size":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false],"large_size":["https:\/\/www.wp.ainiigata.com\/wp-content\/uploads\/2024\/08\/\u8996\u529b\u691c\u67fb\u30a4\u30e1\u30fc\u30b8\u753b\u50cf4.png",254,141,false]},"rttpg_author":{"display_name":"ainiigata","author_link":"https:\/\/www.wp.ainiigata.com\/?author=1"},"rttpg_comment":0,"rttpg_category":"<a href=\"https:\/\/www.wp.ainiigata.com\/?cat=3\" rel=\"category\">\u30a2\u30d7\u30ea<\/a>","rttpg_excerpt":"\u8996\u529b\u691c\u67fb \u8996\u529b\u691c\u67fb \u300c\u2015\u2015\u2015\u2015\u300d\u5de6\u306e\u7dda\u304c\u7d04\uff11cm\u306b\u306a\u308b\u3088\u3046\u306b\u753b\u9762\u30b5\u30a4\u30ba\u3092\u8abf\u6574\u3057\u3066\u304f\u3060\u3055\u3044 \u4f7f\u7528\u65b9\u6cd5: 1. \u753b&hellip;","_links":{"self":[{"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/posts\/361","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=361"}],"version-history":[{"count":8,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/posts\/361\/revisions"}],"predecessor-version":[{"id":371,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/posts\/361\/revisions\/371"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=\/wp\/v2\/media\/358"}],"wp:attachment":[{"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=361"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=361"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wp.ainiigata.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=361"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}