name: gdpr-consent-manager description: 为桌面应用程序实现符合GDPR的同意管理 allowed-tools: Read, Write, Edit, Bash, Glob, Grep tags: [privacy, gdpr, consent, compliance, desktop]
gdpr-consent-manager
为桌面应用程序实现符合GDPR的同意管理,包含用户偏好设置与数据处理功能。
功能
- 生成同意对话框界面
- 存储同意偏好设置
- 实现同意状态检查
- 处理数据导出请求
- 实现数据删除功能
- 配置同意类别
输入模式
{
"type": "object",
"properties": {
"projectPath": { "type": "string" },
"consentCategories": { "type": "array" },
"framework": { "enum": ["electron", "wpf", "qt", "swiftui"] }
},
"required": ["projectPath"]
}
同意类别
const consentCategories = {
necessary: {
title: '必要功能',
description: '基础功能所必需',
required: true
},
analytics: {
title: '分析统计',
description: '帮助我们改进应用',
required: false
},
crashReporting: {
title: '崩溃报告',
description: '帮助我们修复错误',
required: false
}
};
同意存储
const Store = require('electron-store');
const consentStore = new Store({ name: 'consent' });
function getConsent(category) {
return consentStore.get(`consent.${category}`, null);
}
function setConsent(category, granted) {
consentStore.set(`consent.${category}`, granted);
consentStore.set(`consent.timestamp`, Date.now());
}
相关技能
amplitude-desktop-integrationsentry-desktop-setup