Skip to content

Commit f254276

Browse files
committed
#3160 update search static content, and fix search evn banner touch device responsiveness
1 parent a96cbec commit f254276

7 files changed

Lines changed: 47 additions & 37 deletions

File tree

src/assets/data/faqs.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,9 @@
271271
"questionId": "search_cve",
272272
"questionText": "How do I search the CVE List",
273273
"questionResponseParagraphs": [
274-
"<strong>Keyword(s) Search of All CVE Records</strong>",
274+
"<b><i>Search Tips<i></b>",
275+
"<ul><li>By CVE ID<ul><li>Must include only one CVE ID per search.</li><li>CVE ID must include all letters, numbers, and hyphens associated with the CVE ID, e.g., CVE-2024-12345678.</li><li>“CVE” may be entered as “cve”, “CVE”, or as a combination of uppercase and lowercase, as casing is ignored during search.</li></ul></li><li>By other keyword(s)<ul><li>Must contain only alphanumeric characters.</li><li>May contain one or more keywords, separated by a space.</li><li>Keywords may be entered in lowercase, uppercase, or a combination of both. Casing is ignored during search, e.g., Vulnerabilities, vulnerabilities, VULNERABILITIES.</li></ul></li></ul>",
276+
"<strong>2. Other CVE List search options</strong>",
275277
"<ul><li>Search by keyword(s) across <a href='https://github.com/CVEProject/cvelistV5' target='_blank'>ALL FIELDS of all CVE Records</a> in the cvelistV5 downloads repository using the main search box on GitHub.com.</li><li>Search by keyword(s) in the <a href='https://cve.mitre.org/cve/search_cve_list.html' target='_blank'>Description fields ONLY of all CVE Records</a> using the legacy search page on cve.mitre.org.</li></ul>"
276278
]
277279
},

src/components/PrimaryNavigation.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@
127127
<div class="navbar-item cve-secondary-navbar-item cve-keyword-search">
128128
<span class="icon-text mr-2" style="font-size: 14px">
129129
<router-link to="/ResourcesSupport/FAQs#pc_cve_list_basicssearch_cve" class="cve-dark-blue-text">
130-
The legacy CVE List search is available on cve.mitre.org.
130+
Access Search Tips
131131
</router-link>
132132
</span>
133133
</div>

src/components/cveRecordSearchModule.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
aria-labelledby="alertIcon" aria-hidden="false" />
3232
<p class="cve-help-text">
3333
{{ errorMessage }}
34-
<router-link to="/About/Process#request"> Learn more</router-link>
34+
<router-link to="/ResourcesSupport/FAQs#pc_cve_list_basicssearch_cve" class="cve-dark-blue-text">Access Search Tips.</router-link>
3535
</p>
3636
</div>
3737
</div>
@@ -128,7 +128,7 @@ function validateQueryString() {
128128
const cveIdPattern = new RegExp(/^CVE-\d{4}-\d{4,7}$/, 'i').test(cveId);
129129
if (cveId.length > 0 && !cveIdPattern) {
130130
cveListSearchStore.isSeachButtonDisabled = true;
131-
errorMessage.value = 'Only CVE IDs (CVE-YYYY-NNNN) are allowed.';
131+
errorMessage.value = 'Required CVE ID format: CVE-YYYY-NNNN';
132132
cveListSearchStore.showHelpText = true;
133133
} else if (cveId.length === 0) {
134134
cveListSearchStore.isSeachButtonDisabled = true;

src/views/CVERecord/CVERecord.vue

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,17 @@
2626
<p id="alertIconCveRecordsRequestErrored" class="is-hidden">alert</p>
2727
<font-awesome-icon style="flex: 0 0 40px;" size="1x" icon="triangle-exclamation" role="img"
2828
aria-labelledby="alertIconCveRecordsRequestErrored" aria-hidden="false" />
29-
<p>You are viewing <span class="has-text-weight-bold">{{ usingProd }}</span> data from&nbsp;</p>
30-
<a :href="resultUrl" target="_blank"> {{ resultUrl }}
31-
<span class="icon cve-icon-xxs">
32-
<p id="externalLinkIcon" class="is-hidden">external website</p>
33-
<font-awesome-icon icon="up-right-from-square"
34-
aria-labelledby="externalLinkIcon" aria-hidden="false"/>
29+
<p>You are accessing <span class="has-text-weight-bold">{{ usingProd }}</span> data from
30+
<span class="icon-text">
31+
<a :href="resultUrl" target="_blank"> {{ resultUrl }}
32+
<span class="icon cve-icon-xxs">
33+
<p id="externalLinkIcon" class="is-hidden">external website</p>
34+
<font-awesome-icon icon="up-right-from-square"
35+
aria-labelledby="externalLinkIcon" aria-hidden="false"/>
36+
</span>
37+
</a>
3538
</span>
36-
</a>
39+
</p>
3740
</div>
3841
</div>
3942
<PublishedRecord v-if="usecveRecordStore.isPublished"/>

src/views/CVERecord/SearchResults.vue

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,29 @@
2525
<ServiceUnavailable></ServiceUnavailable>
2626
</div>
2727
<div v-else>
28-
<div v-if="Object.keys(cveListSearchStore.recordData).length > 0">
29-
<h2 class="title">CVE Record Lookup</h2>
28+
<div class="notification is-warning is-light" role="alert">
29+
<div v-if="websiteEnv !== 'prd'" class="is-flex is-justify-content-center">
30+
<p id="alertIconCveRecordsRequestErrored" class="is-hidden">alert</p>
31+
<font-awesome-icon style="flex: 0 0 40px;" size="1x" icon="triangle-exclamation" role="alert"
32+
aria-labelledby="alertIconCveRecordsRequestErrored" aria-hidden="false" />
33+
<p>
34+
You are accessing <span class="has-text-weight-bold">Production</span> data from
35+
<span class="icon-text">
36+
<a :href="resultUrl" target="_blank">{{ resultUrl }}
37+
<span class="icon cve-icon-xxs">
38+
<p id="externalLinkIcon" class="is-hidden">external website</p>
39+
<font-awesome-icon icon="up-right-from-square"
40+
aria-labelledby="externalLinkIcon" aria-hidden="false"/>
41+
</span>
42+
</a>
43+
</span>
44+
</p>
45+
</div>
46+
</div>
47+
<div class="mb-3" v-if="Object.keys(cveListSearchStore.recordData).length > 0">
48+
<h2 class="title">CVE Record Found</h2>
3049
<p class="cve-help-text">
31-
Find the information on the specific CVE Record below.
32-
If you're searching for that CVE Record, use the Search Results section below.
50+
See the CVE Record below. If you are searching for this CVE ID in other CVE Records, view the Search Results section below.
3351
</p>
3452
<div class="columns cve-columns is-variable is-1-desktop is-0-mobile mt-5 mr-2 mb-0 ml-2">
3553
<div class="column cve-column">
@@ -63,23 +81,11 @@
6381
</div>
6482
</div>
6583
<div id="cve-search-results-container" v-if="cveListSearchStore.totalSearchResultCount > 0">
66-
<div class="notification is-warning is-light" role="alert">
67-
<div v-if="websiteEnv !== 'prd'" class="is-flex" style="justify-content: center;">
68-
<p id="alertIconCveRecordsRequestErrored" class="is-hidden">alert</p>
69-
<font-awesome-icon style="flex: 0 0 40px;" size="1x" icon="triangle-exclamation" role="img"
70-
aria-labelledby="alertIconCveRecordsRequestErrored" aria-hidden="false" />
71-
<p>You are viewing <span class="has-text-weight-bold">Production</span> data from&nbsp;</p>
72-
<a :href="resultUrl" target="_blank"> {{ resultUrl }}
73-
<span class="icon cve-icon-xxs">
74-
<p id="externalLinkIcon" class="is-hidden">external website</p>
75-
<font-awesome-icon icon="up-right-from-square"
76-
aria-labelledby="externalLinkIcon" aria-hidden="false"/>
77-
</span>
78-
</a>
79-
</div>
80-
</div>
8184
<h2 class="title">Search Results</h2>
82-
<div class="mt-2 mb-2">
85+
<p class="cve-help-text" v-if="Object.keys(cveListSearchStore.recordData).length > 0">
86+
Includes all record(s) that reference this CVE ID.
87+
</p>
88+
<div class="mt-4 mb-2">
8389
<p>
8490
<span>Showing </span>
8591
<span>
@@ -224,8 +230,8 @@
224230
</div>
225231
<div v-else>
226232
<p class="has-text-weight-bold">No search results found for: <span class="is-italic">{{ cveListSearchStore.query }}</span></p>
227-
<p>Please try your search again using the following
228-
<router-link to="/ResourcesSupport/FAQs#pc_cve_list_basicssearch_cve_list_tips">search tips and ticks</router-link> on the FAQs page.
233+
<p>Please try your search again using different keyword(s) or access the
234+
<router-link to="/ResourcesSupport/FAQs#pc_cve_list_basicssearch_cve_list_tips">search tips</router-link>.
229235
</p>
230236
</div>
231237
</div>

src/views/Downloads.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@
7979
{{cvenavs['Downloads']['submenu']['Downloads']['submenu']['Legacy Format']['label']}}
8080
</h2>
8181
<div role="alert" class="notification is-warning is-light">
82-
<div class="is-flex" style="justify-content: center;">
82+
<div class="is-flex is-justify-content-center">
8383
<p id="alertIconVariousFormts" class="is-hidden">alert</p>
8484
<font-awesome-icon style="flex: 0 0 40px;" size="1x" icon="exclamation-triangle" role="alert"
8585
aria-labelledby="alertIconVariousFormts" aria-hidden="false" />

src/views/ResourcesSupport/FAQs.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
:class="{'is-hidden': accordion[item.sectionId + qAndA.questionId]}">
7171
<div v-if="qAndA.questionId == 'search_cve'" class="pb-3">
7272
<p>The following methods are available:</p>
73-
<strong>On this site</strong>
73+
<span class="has-text-weight-bold">1. On this site</span>
7474
<ul>
7575
<li>Search the CVE List by keywords using the
7676
<router-link :to="{ hash: '#cve-secondary-navbar' }">search box</router-link> at the top of this page.
@@ -137,11 +137,10 @@ export default {
137137
</script>
138138

139139
<style lang="scss">
140-
@import '../../assets/style/globals.scss';
140+
@import '@/assets/style/globals.scss';
141141
</style>
142142

143143
<style scoped lang="scss">
144-
@import '@/assets/style/routerLink.scss';
145144
.message {
146145
background-color: unset;
147146
}

0 commit comments

Comments
 (0)