snap-ally 0.2.4-beta → 0.2.7-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -197,12 +197,12 @@ class SnapAllyReporter {
197
197
  }
198
198
  /** Determines the browser name for the current test. */
199
199
  resolveBrowser(test) {
200
- var _a, _b;
200
+ const project = test.parent.project();
201
201
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
202
- const projectUse = ((_a = test.parent.project()) === null || _a === void 0 ? void 0 : _a.use) || {};
203
- return (projectUse.defaultBrowserType ||
202
+ const projectUse = (project === null || project === void 0 ? void 0 : project.use) || {};
203
+ return ((project === null || project === void 0 ? void 0 : project.name) ||
204
204
  projectUse.browserName ||
205
- ((_b = test.parent.project()) === null || _b === void 0 ? void 0 : _b.name) ||
205
+ projectUse.defaultBrowserType ||
206
206
  'chromium');
207
207
  }
208
208
  /** Converts Playwright error objects into HTML-safe strings. */
@@ -117,11 +117,18 @@
117
117
 
118
118
  <!-- Success State -->
119
119
  <div class="success-verified-card" id="a11y-success-card" style="display: none">
120
- <span class="material-symbols-outlined success-hero-icon">check_circle</span>
121
- <h3 class="success-hero-title">Compliance Verified</h3>
122
- <p class="success-hero-desc">
123
- Congratulations! This page passed all automated accessibility checks.
124
- </p>
120
+ <div class="success-content-layout">
121
+ <div class="success-icon-container">
122
+ <span class="material-symbols-outlined">verified_user</span>
123
+ <div class="icon-pulse"></div>
124
+ </div>
125
+ <div class="success-text-group">
126
+ <h3 class="success-hero-title">Compliance Verified</h3>
127
+ <p class="success-hero-desc">
128
+ Congratulations! This page passed all automated accessibility checks.
129
+ </p>
130
+ </div>
131
+ </div>
125
132
  </div>
126
133
 
127
134
  <!-- Violations Container -->
@@ -315,7 +322,7 @@
315
322
  type="text"
316
323
  id="bugAreaInput"
317
324
  class="ado-form-input"
318
- value="Accessibility"
325
+ placeholder="Project\Area"
319
326
  />
320
327
  </div>
321
328
  </div>
@@ -880,7 +880,7 @@ async function submitFinalBug() {
880
880
 
881
881
  const title = document.getElementById('bugTitleInput').value;
882
882
  const severity = document.getElementById('bugSeverityInput').value;
883
- const area = document.getElementById('bugAreaInput').value || 'Accessibility';
883
+ const area = document.getElementById('bugAreaInput').value.replace(/\\+/g, '\\');
884
884
 
885
885
  let screenshotUrl = null;
886
886
  if (screenshotBase64) {
@@ -932,10 +932,18 @@ async function submitFinalBug() {
932
932
  value: `Found at URL / Resource: <a href="${safePageKey}">${safePageKey}</a>`,
933
933
  },
934
934
  { op: 'add', path: '/fields/Microsoft.VSTS.Common.Priority', value: priority },
935
- { op: 'add', path: '/fields/System.AreaPath', value: area.startsWith(proj + '\\') || area === proj ? area : `${proj}\\${area}` },
936
- { op: 'add', path: '/fields/System.Tags', value: 'A11y;SnapAlly;UI-Test' },
937
935
  ];
938
936
 
937
+ if (area) {
938
+ payload.push({
939
+ op: 'add',
940
+ path: '/fields/System.AreaPath',
941
+ value: area.startsWith(proj + '\\') || area === proj ? area : `${proj}\\${area}`,
942
+ });
943
+ }
944
+
945
+ payload.push({ op: 'add', path: '/fields/System.Tags', value: 'A11y;SnapAlly;UI-Test' });
946
+
939
947
  if (screenshotUrl) {
940
948
  payload.push({
941
949
  op: 'add',
@@ -196,11 +196,19 @@
196
196
 
197
197
  <!-- Accessibility Success -->
198
198
  <div class="success-verified-card" id="card-a11y-success" style="display: none">
199
- <span class="material-symbols-outlined success-hero-icon">check_circle</span>
200
- <h3 class="success-hero-title">Compliance Verified</h3>
201
- <p class="success-hero-desc">
202
- Excellent! No accessibility violations were detected for this target resource.
203
- </p>
199
+ <div class="success-content-layout">
200
+ <div class="success-icon-container">
201
+ <span class="material-symbols-outlined">check_circle</span>
202
+ <div class="icon-pulse"></div>
203
+ </div>
204
+ <div class="success-text-group">
205
+ <h3 class="success-hero-title">Compliance Verified</h3>
206
+ <p class="success-hero-desc">
207
+ Excellent! No accessibility violations were detected for this target
208
+ resource.
209
+ </p>
210
+ </div>
211
+ </div>
204
212
  </div>
205
213
 
206
214
  <!-- Accessibility Errors -->
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snap-ally",
3
- "version": "0.2.4-beta",
3
+ "version": "0.2.7-beta",
4
4
  "description": "A custom Playwright reporter for Accessibility testing using Axe, with HTML reporting and Azure DevOps integration.",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",