gdpr-cookie-consent 1.0.0
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 +38 -0
- package/DISCLAIMER.md +104 -0
- package/LICENSE +21 -0
- package/README.md +1119 -0
- package/main.js +1321 -0
- package/package.json +61 -0
- package/types.d.ts +60 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [1.0.0] - 2024-08-03
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- Initial release of GDPR Cookie Consent Library
|
|
12
|
+
- Headless, data-attribute-driven architecture
|
|
13
|
+
- Zero dependencies vanilla JavaScript implementation
|
|
14
|
+
- Comprehensive security features with XSS protection
|
|
15
|
+
- Cookie categories support (analytics, marketing, functional, custom)
|
|
16
|
+
- Script management with conditional loading/unloading
|
|
17
|
+
- Event system with onAccept, onDecline, and onSave callbacks
|
|
18
|
+
- Responsive and accessible design
|
|
19
|
+
- Framework-agnostic compatibility
|
|
20
|
+
- Production-ready error handling
|
|
21
|
+
- Debug mode for development environments
|
|
22
|
+
- CSP-friendly implementation
|
|
23
|
+
- Webflow integration support
|
|
24
|
+
- TypeScript definitions included
|
|
25
|
+
|
|
26
|
+
### Security
|
|
27
|
+
- Input validation and sanitization
|
|
28
|
+
- Script URL validation against malicious injections
|
|
29
|
+
- Secure cookie implementation with proper flags
|
|
30
|
+
- XSS protection throughout the library
|
|
31
|
+
- Safe DOM manipulation practices
|
|
32
|
+
|
|
33
|
+
### Documentation
|
|
34
|
+
- Comprehensive README with examples
|
|
35
|
+
- API reference documentation
|
|
36
|
+
- Integration guides for popular platforms
|
|
37
|
+
- Security best practices guide
|
|
38
|
+
- Troubleshooting documentation
|
package/DISCLAIMER.md
ADDED
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# Legal Disclaimer
|
|
2
|
+
|
|
3
|
+
## ⚖️ IMPORTANT LEGAL NOTICE
|
|
4
|
+
|
|
5
|
+
**THIS SOFTWARE IS A TECHNICAL IMPLEMENTATION TOOL ONLY AND DOES NOT CONSTITUTE LEGAL ADVICE OR GUARANTEE GDPR COMPLIANCE.**
|
|
6
|
+
|
|
7
|
+
### No Legal Advice
|
|
8
|
+
|
|
9
|
+
This library provides technical functionality for implementing cookie consent mechanisms. It is **NOT** legal advice and should **NOT** be considered as such. The author, contributors, and distributors of this software:
|
|
10
|
+
|
|
11
|
+
- Are not lawyers or legal advisors
|
|
12
|
+
- Do not provide legal guidance or compliance advice
|
|
13
|
+
- Cannot guarantee that using this tool will make your website GDPR compliant
|
|
14
|
+
- Strongly recommend consulting with qualified legal professionals
|
|
15
|
+
|
|
16
|
+
### User Responsibility
|
|
17
|
+
|
|
18
|
+
**YOU ARE SOLELY RESPONSIBLE FOR:**
|
|
19
|
+
|
|
20
|
+
1. **Legal Compliance**: Ensuring your website meets all applicable legal requirements including but not limited to GDPR, CCPA, ePrivacy Directive, and other privacy regulations
|
|
21
|
+
2. **Proper Implementation**: Correctly implementing and configuring this tool according to your specific legal requirements
|
|
22
|
+
3. **Legal Review**: Having your implementation reviewed by qualified legal counsel
|
|
23
|
+
4. **Ongoing Compliance**: Maintaining compliance as laws and regulations change
|
|
24
|
+
5. **Cookie Policy**: Creating and maintaining accurate cookie policies and privacy notices
|
|
25
|
+
|
|
26
|
+
### No Warranties
|
|
27
|
+
|
|
28
|
+
This software is provided "AS IS" without warranties of any kind, including but not limited to:
|
|
29
|
+
|
|
30
|
+
- **Legal Compliance**: No warranty that use of this software will result in legal compliance
|
|
31
|
+
- **Accuracy**: No warranty that the software will accurately handle all compliance scenarios
|
|
32
|
+
- **Completeness**: No warranty that the software addresses all legal requirements
|
|
33
|
+
- **Updates**: No warranty that the software will be updated to reflect changing legal requirements
|
|
34
|
+
|
|
35
|
+
### Limitation of Liability
|
|
36
|
+
|
|
37
|
+
**IN NO EVENT SHALL THE AUTHOR, CONTRIBUTORS, OR DISTRIBUTORS BE LIABLE FOR:**
|
|
38
|
+
|
|
39
|
+
- Any legal claims, fines, penalties, or damages arising from non-compliance with privacy laws
|
|
40
|
+
- Any legal costs or expenses incurred due to use of this software
|
|
41
|
+
- Any direct, indirect, incidental, special, or consequential damages
|
|
42
|
+
- Any loss of business, revenue, or data resulting from use of this software
|
|
43
|
+
- Any claims by third parties regarding privacy or data protection violations
|
|
44
|
+
|
|
45
|
+
### Technical Tool Only
|
|
46
|
+
|
|
47
|
+
This software provides technical capabilities including:
|
|
48
|
+
- Cookie consent banner display mechanisms
|
|
49
|
+
- User preference collection and storage
|
|
50
|
+
- Script loading/unloading based on consent
|
|
51
|
+
- Data attribute-driven configuration
|
|
52
|
+
|
|
53
|
+
**What this software DOES NOT provide:**
|
|
54
|
+
- Legal advice or guidance
|
|
55
|
+
- Guarantee of GDPR compliance
|
|
56
|
+
- Cookie categorization guidance
|
|
57
|
+
- Legal text or privacy policy content
|
|
58
|
+
- Regulatory interpretation
|
|
59
|
+
|
|
60
|
+
### Professional Legal Consultation Required
|
|
61
|
+
|
|
62
|
+
**BEFORE IMPLEMENTING THIS TOOL, YOU MUST:**
|
|
63
|
+
|
|
64
|
+
1. Consult with qualified data protection lawyers
|
|
65
|
+
2. Conduct a privacy impact assessment
|
|
66
|
+
3. Review your specific legal obligations
|
|
67
|
+
4. Ensure proper cookie categorization
|
|
68
|
+
5. Create compliant privacy notices and cookie policies
|
|
69
|
+
6. Establish lawful bases for data processing
|
|
70
|
+
7. Implement proper data subject rights procedures
|
|
71
|
+
|
|
72
|
+
### Jurisdictional Considerations
|
|
73
|
+
|
|
74
|
+
Privacy laws vary significantly by jurisdiction. This tool does not:
|
|
75
|
+
- Provide jurisdiction-specific compliance features
|
|
76
|
+
- Account for local privacy law variations
|
|
77
|
+
- Include region-specific legal requirements
|
|
78
|
+
- Guarantee compliance in any specific jurisdiction
|
|
79
|
+
|
|
80
|
+
### Your Acknowledgment
|
|
81
|
+
|
|
82
|
+
By using this software, you acknowledge that:
|
|
83
|
+
|
|
84
|
+
1. You have read and understood this disclaimer
|
|
85
|
+
2. You accept full responsibility for legal compliance
|
|
86
|
+
3. You will consult with qualified legal professionals
|
|
87
|
+
4. You understand this is a technical tool, not legal advice
|
|
88
|
+
5. You assume all risks associated with privacy law compliance
|
|
89
|
+
|
|
90
|
+
### Updates and Changes
|
|
91
|
+
|
|
92
|
+
Legal requirements change frequently. Users are responsible for:
|
|
93
|
+
- Monitoring changes in applicable privacy laws
|
|
94
|
+
- Updating their implementation as needed
|
|
95
|
+
- Ensuring ongoing compliance
|
|
96
|
+
- Seeking updated legal advice as regulations evolve
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
**⚠️ FINAL WARNING: DO NOT RELY ON THIS SOFTWARE ALONE FOR GDPR COMPLIANCE. ALWAYS CONSULT QUALIFIED LEGAL COUNSEL.**
|
|
101
|
+
|
|
102
|
+
For questions about this disclaimer, contact: hello@carterogunsola.com
|
|
103
|
+
|
|
104
|
+
*Last updated: August 3, 2024*
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Carter Ogunsola
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|