mirror of
https://github.com/Choices-js/Choices.git
synced 2024-06-15 20:25:18 +02:00
Update cypress test to assert one placeholder
This commit is contained in:
parent
f0fcf3bca5
commit
e599c0a834
|
@ -458,6 +458,7 @@ describe('Choices - select one', () => {
|
||||||
cy.get('[data-test-hook=remote-data]')
|
cy.get('[data-test-hook=remote-data]')
|
||||||
.find('.choices__list--single')
|
.find('.choices__list--single')
|
||||||
.children()
|
.children()
|
||||||
|
.should('have.length', 1)
|
||||||
.first()
|
.first()
|
||||||
.should('have.class', 'choices__placeholder')
|
.should('have.class', 'choices__placeholder')
|
||||||
.and($placeholder => {
|
.and($placeholder => {
|
||||||
|
|
|
@ -218,7 +218,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.choices__list--dropdown {
|
.choices__list--dropdown {
|
||||||
display: none;
|
visibility: hidden;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -230,10 +230,11 @@
|
||||||
border-bottom-right-radius: 2.5px;
|
border-bottom-right-radius: 2.5px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
|
will-change: visibility;
|
||||||
}
|
}
|
||||||
|
|
||||||
.choices__list--dropdown.is-active {
|
.choices__list--dropdown.is-active {
|
||||||
display: block;
|
visibility: visible;
|
||||||
}
|
}
|
||||||
|
|
||||||
.is-open .choices__list--dropdown {
|
.is-open .choices__list--dropdown {
|
||||||
|
|
2
public/assets/styles/choices.min.css
vendored
2
public/assets/styles/choices.min.css
vendored
File diff suppressed because one or more lines are too long
|
@ -15,43 +15,46 @@
|
||||||
<link
|
<link
|
||||||
rel="apple-touch-icon"
|
rel="apple-touch-icon"
|
||||||
sizes="180x180"
|
sizes="180x180"
|
||||||
href="../assets/images/apple-touch-icon.png"
|
href="../../assets/images/apple-touch-icon.png"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-32x32.png"
|
href="../../assets/images/favicon-32x32.png"
|
||||||
sizes="32x32"
|
sizes="32x32"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-16x16.png"
|
href="../../assets/images/favicon-16x16.png"
|
||||||
sizes="16x16"
|
sizes="16x16"
|
||||||
/>
|
/>
|
||||||
<link rel="manifest" href="../assets/images/manifest.json" />
|
<link rel="manifest" href="../../assets/images/manifest.json" />
|
||||||
<link
|
<link
|
||||||
rel="mask-icon"
|
rel="mask-icon"
|
||||||
href="../assets/images/safari-pinned-tab.svg"
|
href="../../assets/images/safari-pinned-tab.svg"
|
||||||
color="#00bcd4"
|
color="#00bcd4"
|
||||||
/>
|
/>
|
||||||
<link rel="shortcut icon" href="../assets/images/favicon.ico" />
|
<link rel="shortcut icon" href="../../assets/images/favicon.ico" />
|
||||||
<meta
|
<meta
|
||||||
name="msapplication-config"
|
name="msapplication-config"
|
||||||
content="../assets/images/browserconfig.xml"
|
content="../../assets/images/browserconfig.xml"
|
||||||
/>
|
/>
|
||||||
<meta name="theme-color" content="#ffffff" />
|
<meta name="theme-color" content="#ffffff" />
|
||||||
|
|
||||||
<!-- Ignore these -->
|
<!-- Ignore these -->
|
||||||
<link rel="stylesheet" href="../assets/styles/base.min.css?version=6.0.3" />
|
<link
|
||||||
|
rel="stylesheet"
|
||||||
|
href="../../assets/styles/base.min.css?version=6.0.3"
|
||||||
|
/>
|
||||||
<!-- End ignore these -->
|
<!-- End ignore these -->
|
||||||
|
|
||||||
<!-- Choices includes -->
|
<!-- Choices includes -->
|
||||||
<link
|
<link
|
||||||
rel="stylesheet"
|
rel="stylesheet"
|
||||||
href="../assets/styles/choices.min.css?version=6.0.3"
|
href="../../assets/styles/choices.min.css?version=6.0.3"
|
||||||
/>
|
/>
|
||||||
<script src="../assets/scripts/choices.min.js?version=6.0.3"></script>
|
<script src="../../assets/scripts/choices.min.js?version=6.0.3"></script>
|
||||||
<!-- End Choices includes -->
|
<!-- End Choices includes -->
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
@ -215,7 +218,9 @@
|
||||||
name="choices-remote-data"
|
name="choices-remote-data"
|
||||||
id="choices-remote-data"
|
id="choices-remote-data"
|
||||||
multiple
|
multiple
|
||||||
></select>
|
>
|
||||||
|
<option value="">Placeholder</option>
|
||||||
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div data-test-hook="scrolling-dropdown">
|
<div data-test-hook="scrolling-dropdown">
|
||||||
|
|
|
@ -15,43 +15,46 @@
|
||||||
<link
|
<link
|
||||||
rel="apple-touch-icon"
|
rel="apple-touch-icon"
|
||||||
sizes="180x180"
|
sizes="180x180"
|
||||||
href="../assets/images/apple-touch-icon.png"
|
href="../../assets/images/apple-touch-icon.png"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-32x32.png"
|
href="../../assets/images/favicon-32x32.png"
|
||||||
sizes="32x32"
|
sizes="32x32"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-16x16.png"
|
href="../../assets/images/favicon-16x16.png"
|
||||||
sizes="16x16"
|
sizes="16x16"
|
||||||
/>
|
/>
|
||||||
<link rel="manifest" href="../assets/images/manifest.json" />
|
<link rel="manifest" href="../../assets/images/manifest.json" />
|
||||||
<link
|
<link
|
||||||
rel="mask-icon"
|
rel="mask-icon"
|
||||||
href="../assets/images/safari-pinned-tab.svg"
|
href="../../assets/images/safari-pinned-tab.svg"
|
||||||
color="#00bcd4"
|
color="#00bcd4"
|
||||||
/>
|
/>
|
||||||
<link rel="shortcut icon" href="../assets/images/favicon.ico" />
|
<link rel="shortcut icon" href="../../assets/images/favicon.ico" />
|
||||||
<meta
|
<meta
|
||||||
name="msapplication-config"
|
name="msapplication-config"
|
||||||
content="../assets/images/browserconfig.xml"
|
content="../../assets/images/browserconfig.xml"
|
||||||
/>
|
/>
|
||||||
<meta name="theme-color" content="#ffffff" />
|
<meta name="theme-color" content="#ffffff" />
|
||||||
|
|
||||||
<!-- Ignore these -->
|
<!-- Ignore these -->
|
||||||
<link rel="stylesheet" href="../assets/styles/base.min.css?version=6.0.3" />
|
<link
|
||||||
|
rel="stylesheet"
|
||||||
|
href="../../assets/styles/base.min.css?version=6.0.3"
|
||||||
|
/>
|
||||||
<!-- End ignore these -->
|
<!-- End ignore these -->
|
||||||
|
|
||||||
<!-- Choices includes -->
|
<!-- Choices includes -->
|
||||||
<link
|
<link
|
||||||
rel="stylesheet"
|
rel="stylesheet"
|
||||||
href="../assets/styles/choices.min.css?version=6.0.3"
|
href="../../assets/styles/choices.min.css?version=6.0.3"
|
||||||
/>
|
/>
|
||||||
<script src="../assets/scripts/choices.min.js?version=6.0.3"></script>
|
<script src="../../assets/scripts/choices.min.js?version=6.0.3"></script>
|
||||||
<!-- End Choices includes -->
|
<!-- End Choices includes -->
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
@ -184,7 +187,9 @@
|
||||||
class="form-control"
|
class="form-control"
|
||||||
name="choices-remote-data"
|
name="choices-remote-data"
|
||||||
id="choices-remote-data"
|
id="choices-remote-data"
|
||||||
></select>
|
>
|
||||||
|
<option value="">Placeholder</option>
|
||||||
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div data-test-hook="scrolling-dropdown">
|
<div data-test-hook="scrolling-dropdown">
|
||||||
|
|
|
@ -15,43 +15,46 @@
|
||||||
<link
|
<link
|
||||||
rel="apple-touch-icon"
|
rel="apple-touch-icon"
|
||||||
sizes="180x180"
|
sizes="180x180"
|
||||||
href="../assets/images/apple-touch-icon.png"
|
href="../../assets/images/apple-touch-icon.png"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-32x32.png"
|
href="../../assets/images/favicon-32x32.png"
|
||||||
sizes="32x32"
|
sizes="32x32"
|
||||||
/>
|
/>
|
||||||
<link
|
<link
|
||||||
rel="icon"
|
rel="icon"
|
||||||
type="image/png"
|
type="image/png"
|
||||||
href="../assets/images/favicon-16x16.png"
|
href="../../assets/images/favicon-16x16.png"
|
||||||
sizes="16x16"
|
sizes="16x16"
|
||||||
/>
|
/>
|
||||||
<link rel="manifest" href="../assets/images/manifest.json" />
|
<link rel="manifest" href="../../assets/images/manifest.json" />
|
||||||
<link
|
<link
|
||||||
rel="mask-icon"
|
rel="mask-icon"
|
||||||
href="../assets/images/safari-pinned-tab.svg"
|
href="../../assets/images/safari-pinned-tab.svg"
|
||||||
color="#00bcd4"
|
color="#00bcd4"
|
||||||
/>
|
/>
|
||||||
<link rel="shortcut icon" href="../assets/images/favicon.ico" />
|
<link rel="shortcut icon" href="../../assets/images/favicon.ico" />
|
||||||
<meta
|
<meta
|
||||||
name="msapplication-config"
|
name="msapplication-config"
|
||||||
content="../assets/images/browserconfig.xml"
|
content="../../assets/images/browserconfig.xml"
|
||||||
/>
|
/>
|
||||||
<meta name="theme-color" content="#ffffff" />
|
<meta name="theme-color" content="#ffffff" />
|
||||||
|
|
||||||
<!-- Ignore these -->
|
<!-- Ignore these -->
|
||||||
<link rel="stylesheet" href="../assets/styles/base.min.css?version=6.0.3" />
|
<link
|
||||||
|
rel="stylesheet"
|
||||||
|
href="../../assets/styles/base.min.css?version=6.0.3"
|
||||||
|
/>
|
||||||
<!-- End ignore these -->
|
<!-- End ignore these -->
|
||||||
|
|
||||||
<!-- Choices includes -->
|
<!-- Choices includes -->
|
||||||
<link
|
<link
|
||||||
rel="stylesheet"
|
rel="stylesheet"
|
||||||
href="../assets/styles/choices.min.css?version=6.0.3"
|
href="../../assets/styles/choices.min.css?version=6.0.3"
|
||||||
/>
|
/>
|
||||||
<script src="../assets/scripts/choices.min.js?version=6.0.3"></script>
|
<script src="../../assets/scripts/choices.min.js?version=6.0.3"></script>
|
||||||
<!-- End Choices includes -->
|
<!-- End Choices includes -->
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue