Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AMP-3313: fix deprecated named / scoped slot syntax #527

Merged
merged 2 commits into from
Jul 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
93 changes: 47 additions & 46 deletions src/components/batch/BatchIngest.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,53 +102,54 @@
</div>
</div>
<modal class="my-modal" v-if="showModal" @close="reset()">
<h3
slot="header"
v-if="validationResponse && !validationResponse.success"
>
Batch Ingest Errors
</h3>
<h3 slot="header" v-else>Batch Submitted Successfully!</h3>
<div slot="body">
<div
v-if="
validationResponse &&
!validationResponse.success &&
validationResponse.validationErrors.length > 0
"
class="batch-errors"
>
<p>There is an error validating your batch.</p>
<ul>
<li
class="error-li"
v-for="(error, index) in validationResponse.validationErrors"
v-bind:key="index"
>
{{ error }}
</li>
</ul>
</div>
<div
v-else-if="validationResponse && !validationResponse.success"
class="batch-errors"
>
<p>There is an error processing your batch.</p>
<ul>
<li
class="error-li"
v-for="(error, index) in validationResponse.processingErrors"
v-bind:key="index"
>
{{ error }}
</li>
</ul>
</div>
<div v-else>
Your batch has been successfully submitted and all files are ready
to be submitted to a workflow.
<template #header>
<h3 v-if="validationResponse && !validationResponse.success">
Batch Ingest Errors
</h3>
<h3 v-else>Batch Submitted Successfully!</h3>
</template>
<template #body>
<div>
<div
v-if="
validationResponse &&
!validationResponse.success &&
validationResponse.validationErrors.length > 0
"
class="batch-errors"
>
<p>There is an error validating your batch.</p>
<ul>
<li
class="error-li"
v-for="(error, index) in validationResponse.validationErrors"
v-bind:key="index"
>
{{ error }}
</li>
</ul>
</div>
<div
v-else-if="validationResponse && !validationResponse.success"
class="batch-errors"
>
<p>There is an error processing your batch.</p>
<ul>
<li
class="error-li"
v-for="(error, index) in validationResponse.processingErrors"
v-bind:key="index"
>
{{ error }}
</li>
</ul>
</div>
<div v-else>
Your batch has been successfully submitted and all files are ready
to be submitted to a workflow.
</div>
</div>
</div>
</template>
</modal>
</div>
</div>
Expand Down
196 changes: 100 additions & 96 deletions src/components/deliverables/Deliverables.vue
Original file line number Diff line number Diff line change
Expand Up @@ -101,106 +101,110 @@
</div>
</div>
<modal class="my-modal" v-if="showModal" @close="showModal = false">
<h3 slot="header">Search</h3>
<div slot="body">
<div class="input-group mb-3">
<input
v-model="searchWord"
type="text"
class="form-control"
placeholder="Search"
v-on:keyup.enter="searchKeyUp"
v-on:keyup.down="onArrowDown"
ref="searchInput"
tabindex="0"
/>
<div class="input-group-append">
<button
v-on:click="searchFiles"
class="btn btn-success"
type="button"
<template #header><h3>Search</h3></template>
<template #body>
<div>
<div class="input-group mb-3">
<input
v-model="searchWord"
type="text"
class="form-control"
placeholder="Search"
v-on:keyup.enter="searchKeyUp"
v-on:keyup.down="onArrowDown"
ref="searchInput"
tabindex="0"
/>
<div class="input-group-append">
<button
v-on:click="searchFiles"
class="btn btn-success"
type="button"
>
Go
</button>
</div>
</div>
<div class="scrollDiv">
<table
id="myTable"
data-detail-view="true"
class="table"
ref="tbl"
>
Go
</button>
<thead>
<tr>
<th data-sortable="true" data-field="collectionName">
Collection
</th>
<th data-sortable="true" data-field="itemName">Item</th>
<th data-sortable="true" data-field="externalSource">
External Source
</th>
<th data-sortable="true" data-field="externalId">
External ID
</th>
<th data-sortable="true" data-field="primaryfileName">
Content File
</th>
<th
data-sortable="true"
data-field="primaryfileOriginalname"
>
Filename
</th>
</tr>
</thead>
<tbody>
<tr
class="deliverables-search"
v-for="(pfile, index) in searchedPfiles"
v-bind:key="index"
:ref="'row' + index"
tabindex="0"
v-on:keyup.down="onArrowDown"
v-on:keyup.up="onArrowUp"
v-on:click="rowClicked(index)"
:class="{
'table-dark': rowSelected(pfile.primaryfileId),
}"
>
<td>{{ pfile.collectionName }}</td>
<td>{{ pfile.itemName }}</td>
<td>{{ pfile.externalSource }}</td>
<td>{{ pfile.externalId }}</td>
<td>{{ pfile.primaryfileName }}</td>
<td
style="max-width: 30px !important; overflow-wrap: break-word;"
>
{{ pfile.primaryfileOriginalname }}
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="scrollDiv">
<table
id="myTable"
data-detail-view="true"
class="table"
ref="tbl"
</template>
<template #footer>
<slot class="my-modal-footer">
<button
type="button"
class="btn btn-outline pull-left"
data-dismiss="modal"
v-on:click="close()"
aria-label="Close"
>
<thead>
<tr>
<th data-sortable="true" data-field="collectionName">
Collection
</th>
<th data-sortable="true" data-field="itemName">Item</th>
<th data-sortable="true" data-field="externalSource">
External Source
</th>
<th data-sortable="true" data-field="externalId">
External ID
</th>
<th data-sortable="true" data-field="primaryfileName">
Content File
</th>
<th
data-sortable="true"
data-field="primaryfileOriginalname"
>
Filename
</th>
</tr>
</thead>
<tbody>
<tr
class="deliverables-search"
v-for="(pfile, index) in searchedPfiles"
v-bind:key="index"
:ref="'row' + index"
tabindex="0"
v-on:keyup.down="onArrowDown"
v-on:keyup.up="onArrowUp"
v-on:click="rowClicked(index)"
:class="{
'table-dark': rowSelected(pfile.primaryfileId),
}"
>
<td>{{ pfile.collectionName }}</td>
<td>{{ pfile.itemName }}</td>
<td>{{ pfile.externalSource }}</td>
<td>{{ pfile.externalId }}</td>
<td>{{ pfile.primaryfileName }}</td>
<td
style="max-width: 30px !important; overflow-wrap: break-word;"
>
{{ pfile.primaryfileOriginalname }}
</td>
</tr>
</tbody>
</table>
</div>
</div>
<slot slot="footer" class="my-modal-footer">
<button
type="button"
class="btn btn-outline pull-left"
data-dismiss="modal"
v-on:click="close()"
aria-label="Close"
>
Cancel
</button>
<button
type="button"
class="btn btn-primary"
v-on:click="done()"
>
Done
</button>
</slot>
Cancel
</button>
<button
type="button"
class="btn btn-primary"
v-on:click="done()"
>
Done
</button>
</slot>
</template>
</modal>
</main>
</div>
Expand Down
16 changes: 8 additions & 8 deletions src/components/hmgm/NerEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -46,17 +46,17 @@
</div>
</div>
<modal v-if="showResponse" @close="modalDismiss">
<h3 slot="header">{{ responseHeader }}</h3>
<div slot="body">
<template #header><h3>{{ responseHeader }}</h3></template>
<template #body><div>
{{ responseBody }}
</div>
</div></template>
</modal>
<modal v-if="showConfirm" @close="showConfirm = false">
<h3 slot="header">{{ confirmHeader }}</h3>
<div slot="body">
<template #header><h3>{{ confirmHeader }}</h3></template>
<template #body><div>
{{ confirmBody }}
</div>
<div slot="footer" class="action-buttons">
</div>></template>
<template #footer><div class="action-buttons">
<input
type="button"
class="secondary-button"
Expand All @@ -69,7 +69,7 @@
v-on:click="onConfirm"
value="Continue"
/>
</div>
</div></template>
</modal>
<token-validator
v-if="showTokenValidator"
Expand Down
10 changes: 5 additions & 5 deletions src/components/hmgm/TokenValidator.vue
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<template>
<div>
<modal class="my-modal">
<h5 slot="header">Authentication Required</h5>
<div slot="body">
<template #header><h5>Authentication Required</h5></template>
<template #body><div>
Enter the editor password to view the page:
<div class="form-input">
<label class="form-errors" v-if="invalidInput"
Expand All @@ -14,15 +14,15 @@
v-on:keyup.enter="submitToken"
/>
</div>
</div>
<div slot="footer">
</div>></template>
<template #footer><div>
<input
type="button"
class="primary-button"
value="Submit"
v-on:click="submitToken"
/>
</div>
</div></template>
</modal>
</div>
</template>
Expand Down
Loading
Loading