|
5 | 5 | <div v-if="route.name.startsWith('type-id-settings')" class="normal-page no-sidebar">
|
6 | 6 | <div class="normal-page__header">
|
7 | 7 | <div
|
8 |
| - class="mb-4 flex items-center gap-2 border-0 border-b-[1px] border-solid border-divider pb-4 text-lg font-semibold" |
| 8 | + class="mb-4 flex flex-wrap items-center gap-x-2 gap-y-3 border-0 border-b-[1px] border-solid border-divider pb-4 text-lg font-semibold" |
9 | 9 | >
|
10 | 10 | <nuxt-link
|
11 | 11 | :to="`/${project.project_type}/${project.slug ? project.slug : project.id}`"
|
|
759 | 759 | projectV3.environment[0] !== 'unknown'
|
760 | 760 | "
|
761 | 761 | type="warning"
|
762 |
| - :header="formatMessage(messages.environmentMigrationTitle)" |
| 762 | + :header=" |
| 763 | + formatMessage( |
| 764 | + hasEditDetailsPermission |
| 765 | + ? messages.environmentMigrationTitle |
| 766 | + : messages.environmentMigrationNoPermissionTitle, |
| 767 | + ) |
| 768 | + " |
763 | 769 | class="mt-3"
|
764 | 770 | >
|
765 |
| - {{ formatMessage(messages.environmentMigrationMessage) }} |
766 |
| - <ButtonStyled color="orange"> |
767 |
| - <nuxt-link |
768 |
| - v-tooltip=" |
769 |
| - hasEditDetailsPermission |
770 |
| - ? undefined |
771 |
| - : formatMessage(commonProjectSettingsMessages.noPermissionDescription) |
772 |
| - " |
773 |
| - :to="`/project/${project.id}/settings/environment`" |
774 |
| - class="mt-3 w-fit" |
775 |
| - :disabled="!hasEditDetailsPermission" |
776 |
| - > |
| 771 | + {{ |
| 772 | + formatMessage( |
| 773 | + hasEditDetailsPermission |
| 774 | + ? messages.environmentMigrationMessage |
| 775 | + : messages.environmentMigrationNoPermissionMessage, |
| 776 | + ) |
| 777 | + }} |
| 778 | + <nuxt-link |
| 779 | + to="/news/article/new-environments" |
| 780 | + target="_blank" |
| 781 | + class="mt-1 block w-fit font-semibold text-orange hover:underline" |
| 782 | + > |
| 783 | + {{ formatMessage(messages.environmentMigrationLink) }} |
| 784 | + </nuxt-link> |
| 785 | + <ButtonStyled v-if="hasEditDetailsPermission" color="orange"> |
| 786 | + <nuxt-link :to="`/project/${project.id}/settings/environment`" class="mt-3 w-fit"> |
777 | 787 | <SettingsIcon /> {{ formatMessage(messages.reviewEnvironmentSettings) }}
|
778 | 788 | </nuxt-link>
|
779 | 789 | </ButtonStyled>
|
@@ -966,7 +976,6 @@ import {
|
966 | 976 | ButtonStyled,
|
967 | 977 | Checkbox,
|
968 | 978 | commonMessages,
|
969 |
| - commonProjectSettingsMessages, |
970 | 979 | injectNotificationManager,
|
971 | 980 | NewModal,
|
972 | 981 | OverflowMenu,
|
@@ -1152,6 +1161,19 @@ const messages = defineMessages({
|
1152 | 1161 | id: 'project.environment.migration.title',
|
1153 | 1162 | defaultMessage: 'Please review environment metadata',
|
1154 | 1163 | },
|
| 1164 | + environmentMigrationNoPermissionMessage: { |
| 1165 | + id: 'project.environment.migration-no-permission.message', |
| 1166 | + defaultMessage: |
| 1167 | + "We've just overhauled the Environments system on Modrinth and new options are now available. You don't have permission to modify these settings, but please let another member of the project know that the environment metadata needs to be verified.", |
| 1168 | + }, |
| 1169 | + environmentMigrationNoPermissionTitle: { |
| 1170 | + id: 'project.environment.migration-no-permission.title', |
| 1171 | + defaultMessage: 'Environment metadata needs to be reviewed', |
| 1172 | + }, |
| 1173 | + environmentMigrationLink: { |
| 1174 | + id: 'project.environment.migration.learn-more', |
| 1175 | + defaultMessage: 'Learn more about this change', |
| 1176 | + }, |
1155 | 1177 | followersStat: {
|
1156 | 1178 | id: 'project.stats.followers-label',
|
1157 | 1179 | defaultMessage: 'follower{count, plural, one {} other {s}}',
|
|
0 commit comments