@networkpro/web 1.25.2 → 1.25.3

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.
package/CHANGELOG.md CHANGED
@@ -22,7 +22,20 @@ This project attempts to follow [Keep a Changelog](https://keepachangelog.com/en
22
22
 
23
23
  ---
24
24
 
25
- ## [1.25.2]
25
+ ## [1.25.3] - 2025-11-03
26
+
27
+ ### Changed
28
+
29
+ - Updated `posthog.js` to display environmental context logs only in development and testing environments.
30
+ - Bumped project version to `v1.25.3`.
31
+
32
+ ### Removed
33
+
34
+ - Removed **Branch Guard** workflow (`.github/workflows/branch-guard.yml`), as it was resulting in mostly false positives.
35
+
36
+ ---
37
+
38
+ ## [1.25.2] - 2025-11-03
26
39
 
27
40
  ### Changed
28
41
 
@@ -46,7 +59,7 @@ This project attempts to follow [Keep a Changelog](https://keepachangelog.com/en
46
59
 
47
60
  ---
48
61
 
49
- ## [1.25.1]
62
+ ## [1.25.1] - 2025-11-02
50
63
 
51
64
  ### Added
52
65
 
@@ -74,7 +87,7 @@ This project attempts to follow [Keep a Changelog](https://keepachangelog.com/en
74
87
 
75
88
  ---
76
89
 
77
- ## [1.25.0]
90
+ ## [1.25.0] - 2025-11-02
78
91
 
79
92
  ### Added
80
93
 
@@ -1636,7 +1649,8 @@ This enables analytics filtering and CSP hardening for the audit environment.
1636
1649
 
1637
1650
  <!-- Link references -->
1638
1651
 
1639
- [Unreleased]: https://github.com/netwk-pro/netwk-pro.github.io/compare/v1.25.2...HEAD
1652
+ [Unreleased]: https://github.com/netwk-pro/netwk-pro.github.io/compare/v1.25.3...HEAD
1653
+ [1.25.3]: https://github.com/netwk-pro/netwk-pro.github.io/releases/tag/v1.25.3
1640
1654
  [1.25.2]: https://github.com/netwk-pro/netwk-pro.github.io/releases/tag/v1.25.2
1641
1655
  [1.25.1]: https://github.com/netwk-pro/netwk-pro.github.io/releases/tag/v1.25.1
1642
1656
  [1.25.0]: https://github.com/netwk-pro/netwk-pro.github.io/releases/tag/v1.25.0
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@networkpro/web",
3
3
  "private": false,
4
- "version": "1.25.2",
4
+ "version": "1.25.3",
5
5
  "description": "Locking Down Networks, Unlocking Confidence™ | Security, Networking, Privacy — Network Pro Strategies",
6
6
  "keywords": [
7
7
  "advisory",
@@ -51,16 +51,19 @@ export async function initPostHog() {
51
51
  const host = window.location.hostname;
52
52
  const isAuditHost = /(^|\.)audit\.netwk\.pro$/i.test(host);
53
53
  const effectiveAudit = isAudit || isAuditHost;
54
+ const isDebug = isDev || isTest;
54
55
 
55
56
  // 🧭 Log environment context before any conditional logic
56
- console.info('[PostHog ENV]', {
57
- buildMode: mode,
58
- effectiveMode: effective,
59
- host,
60
- effectiveAudit,
61
- isDev,
62
- isTest,
63
- });
57
+ if (isDebug) {
58
+ console.info('[PostHog ENV]', {
59
+ buildMode: mode,
60
+ effectiveMode: effective,
61
+ host,
62
+ effectiveAudit,
63
+ isDev,
64
+ isTest,
65
+ });
66
+ }
64
67
 
65
68
  // 🚫 Skip analytics in audit context
66
69
  if (effectiveAudit) {
@@ -71,7 +74,7 @@ export async function initPostHog() {
71
74
  }
72
75
 
73
76
  // 🧱 Skip entirely in dev/test contexts
74
- if (isDev || isTest) {
77
+ if (isDebug) {
75
78
  console.info('[PostHog] Skipping init in dev/test mode.');
76
79
  return;
77
80
  }
@@ -1,53 +0,0 @@
1
- # .github/workflows/branch-guard.yml
2
- #
3
- # Copyright © 2025 Network Pro Strategies (Network Pro™)
4
- # SPDX-License-Identifier: CC-BY-4.0 OR GPL-3.0-or-later
5
- # This file is part of Network Pro
6
- #
7
- # Warns if commits are pushed directly to master/main instead of via PR.
8
- # Does NOT block the commit — it just posts a workflow summary and log warning.
9
-
10
- name: Branch Guard
11
-
12
- on:
13
- push:
14
- branches:
15
- - master
16
- - main
17
-
18
- permissions:
19
- contents: read
20
-
21
- jobs:
22
- warn-direct-commit:
23
- runs-on: ubuntu-24.04
24
- steps:
25
- - name: Check commit source
26
- run: |
27
- commit_msg="${{ github.event.head_commit.message }}"
28
- actor="${{ github.actor }}"
29
- branch="${GITHUB_REF##*/}"
30
-
31
- echo "📝 Commit message: $commit_msg"
32
- echo "👤 Actor: $actor"
33
- echo "🌿 Branch: $branch"
34
-
35
- # Define known safe patterns (merge or bot commits)
36
- if echo "$commit_msg" | grep -Eq "Merge pull request|See merge request|Merge branch|(#\d+)$"; then
37
- echo "✅ Merge-related commit detected — no warning."
38
- exit 0
39
- fi
40
-
41
- if [[ "$actor" == "dependabot[bot]" ]] || [[ "$actor" == "renovate[bot]" ]] || [[ "$actor" == "github-actions[bot]" ]]; then
42
- echo "🤖 Bot commit detected — skipping warning."
43
- exit 0
44
- fi
45
-
46
- # Otherwise, warn for direct commits
47
- echo "::warning ::⚠️ Direct commit to $branch by $actor."
48
- {
49
- echo "### ⚠️ Direct Commit Detected"
50
- echo "A commit was pushed directly to \`$branch\` by **$actor**."
51
- echo ""
52
- echo "💡 It's recommended to use pull requests for traceability and CI validation."
53
- } >> $GITHUB_STEP_SUMMARY