📦 EqualifyEverything / equalify-v2-dashboard-mocks

📄 4-audit_builder-pages_added.html · 116 lines
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Audit Builder - Equalify</title>
</head>
<body>
    <main>
        <h1>Audit Builder - Step 1</h1>
        <div aria-live="assertive">2 pages added.</div>
        <nav aria-label="Breadcrumb">
            <ol>
                <li><a href="#" aria-current="page">Add and Review Pages</a></li>
                <li><a href="#">Set Audit Options</a></li>
            </ol>
        </nav>
        <section>
            <h2>Add Pages</h2>
            <form>
                <label for="importer">Import By:</label>
                <select id="importer">
                    <option selected>Page URLs</option>
                    <option>Sitemap</option>
                    <option>CSV</option>
                </select>
                <div id="page-url-section">
                    <label for="urls">Page URLs:</label>
                    <input id="urls" type="text" required>
                </div>
                <div id="sitemap-section" style="display:none;">
                    <label for="sitemap-url">Sitemap URL:</label>
                    <input id="sitemap-url" type="url">
                </div>
                <div id="csv-section" style="display:none;">
                    <label for="csv-upload">CSV Upload:</label>
                    <input id="csv-upload" type="file" accept=".csv">
                </div>
                <button>Add Pages</button>
            </form>
            
            <script>
                document.getElementById("importer").addEventListener("change", function() {
                    var selectedOption = this.value;
                    
                    // Hide all sections
                    document.getElementById("page-url-section").style.display = "none";
                    document.getElementById("sitemap-section").style.display = "none";
                    document.getElementById("csv-section").style.display = "none";
                    
                    // Show the appropriate section based on selection
                    if (selectedOption === "Page URLs") {
                        document.getElementById("page-url-section").style.display = "block";
                    } else if (selectedOption === "Sitemap") {
                        document.getElementById("sitemap-section").style.display = "block";
                    } else if (selectedOption === "CSV") {
                        document.getElementById("csv-section").style.display = "block";
                    }
                });
            </script>    
        </section>
        <section>
            <h2>Review Added Pages</h2>
            <input id="all-added-pages" type="checkbox" class="select_all"> <label for="all-added-pages">Select All Added Pages</label>        
            <table id="added_pages">
                <thead>
                    <tr>
                        <th role="columnheader">URL</th>
                        <th role="columnheader">Type</th>
                    </tr>
                </thead>
                <tbody>
                    <tr>
                        <th role="rowheader"><input type="checkbox" id="checkbox-1"><label for="checkbox-1"> https://update.lib.berkeley.edu/</label></th>
                        <th>
                            <select id="importer">
                                <option selected>HTML</option>
                                <option>PDF</option>
                            </select>
                        </th>
                    </tr>
                    <tr>
                        <th role="rowheader"><input type="checkbox" id="checkbox-2"><label for="checkbox-2">  https://www-stg.berkeley.edu</label></th>
                        <th>
                            <select id="importer">
                                <option selected>HTML</option>
                                <option>PDF</option>
                            </select>
                        </th>
                    </tr>
                </tbody>
            </table>
            <nav aria-label="Edit Added Pages">
                <button>Remove Pages</button>
            </nav>
            <nav aria-label="Added Pages Table">
                <label for="item-count">Showing 2 of 2 Pages. Change Number of Pages Displayed:</label> 
                <select id="item-count">
                    <option selected>Up to 5</option>
                </select>
            </nav>
            <script>
                document.querySelectorAll('.select_all').forEach(selectAllCheckbox => {
                    selectAllCheckbox.addEventListener('change', function() {
                        const parent = this.closest('div, table, details, section');
                        const checkboxes = parent.querySelectorAll('input[type="checkbox"]:not(.select_all)');
                        checkboxes.forEach(checkbox => checkbox.checked = this.checked);
                    });
                });
            </script>
        </section>
        <button onclick="window.location.href='5-audit_builder-add_checks.html';">Next Step</button>
    </main>
</body>
</html>