diff --git a/DESIGN.md b/DESIGN.md index 775b62954..df364c719 100644 --- a/DESIGN.md +++ b/DESIGN.md @@ -8,3 +8,20 @@ ring, while the selected control retains the blue card border. Contact-us cards use a non-submitting button so they remain keyboard operable without becoming a checkout selection. After a plan refresh, focus returns to the selected radio only when the visitor has not moved it elsewhere during the request. + +## Domain DNS lookup + +DNS lookup without a configured integration is a normal read-only state, not a +warning. Use a neutral gray information strip with a secondary configuration +link; reserve warning/error styling for actual failures. + +Show returned NS records in a separate nameserver summary, using escaped text +and hiding the entire summary when none are returned. Nameservers may help identify +the DNS host, but do not infer a provider name or imply an integration is enabled. + +### Responsive behaviour + +Keep the existing stacked widget layout on desktop and mobile. List nameservers +on separate lines and allow long hostnames to wrap without truncation. Hide the +summary during loading or lookup errors; preserve the existing record table and +provider-managed editing controls. diff --git a/assets/js/dns-table.js b/assets/js/dns-table.js index aa5aa3458..da3ae730e 100644 --- a/assets/js/dns-table.js +++ b/assets/js/dns-table.js @@ -8,6 +8,17 @@ results: {}, loading: true, }, + computed: { + nameservers() { + const records = (this.results.entries || []).concat(this.results.auth || []); + const nameservers = records + .filter((record) => record.type === 'NS' && typeof record.data === 'string') + .map((record) => record.data.replace(/\.$/, '').toLowerCase()) + .filter((nameserver) => nameserver); + + return [ ...new Set(nameservers) ].sort(); + }, + }, updated() { this.$nextTick(function() { diff --git a/views/domain/admin-dns-management.php b/views/domain/admin-dns-management.php index 21959d666..0a6cf441f 100644 --- a/views/domain/admin-dns-management.php +++ b/views/domain/admin-dns-management.php @@ -144,10 +144,10 @@ class="wubox wu-text-red-600 hover:wu-text-red-800" -
- +
+ - + @@ -156,6 +156,13 @@ class="wubox wu-text-red-600 hover:wu-text-red-800"
+
+ +
    +
  • {{ nameserver }}
  • +
+

+