@atproto/api 0.19.4 → 0.19.5

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.
Files changed (35) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/agent.d.ts +6 -5
  3. package/dist/agent.d.ts.map +1 -1
  4. package/dist/agent.js +6 -2
  5. package/dist/agent.js.map +1 -1
  6. package/dist/atp-agent.d.ts +0 -1
  7. package/dist/atp-agent.d.ts.map +1 -1
  8. package/dist/atp-agent.js +0 -3
  9. package/dist/atp-agent.js.map +1 -1
  10. package/dist/client/lexicons.d.ts +12 -12
  11. package/dist/client/lexicons.d.ts.map +1 -1
  12. package/dist/client/lexicons.js +7 -10
  13. package/dist/client/lexicons.js.map +1 -1
  14. package/dist/client/types/app/bsky/graph/getSuggestedFollowsByActor.d.ts +3 -3
  15. package/dist/client/types/app/bsky/graph/getSuggestedFollowsByActor.d.ts.map +1 -1
  16. package/dist/client/types/app/bsky/graph/getSuggestedFollowsByActor.js.map +1 -1
  17. package/dist/client/types/com/atproto/label/defs.d.ts +1 -1
  18. package/dist/client/types/com/atproto/label/defs.d.ts.map +1 -1
  19. package/dist/client/types/com/atproto/label/defs.js.map +1 -1
  20. package/dist/index.d.ts +2 -1
  21. package/dist/index.d.ts.map +1 -1
  22. package/dist/index.js +4 -1
  23. package/dist/index.js.map +1 -1
  24. package/package.json +5 -4
  25. package/scripts/code/labels.mjs +20 -17
  26. package/scripts/generate-code.mjs +3 -2
  27. package/src/agent.ts +10 -7
  28. package/src/atp-agent.ts +0 -4
  29. package/src/client/lexicons.ts +8 -11
  30. package/src/client/types/app/bsky/graph/getSuggestedFollowsByActor.ts +3 -3
  31. package/src/client/types/com/atproto/label/defs.ts +2 -5
  32. package/src/index.ts +3 -1
  33. package/tests/errors.test.ts +1 -1
  34. package/tests/moderation-prefs.test.ts +9 -9
  35. package/src/moderation/const/labels.ts +0 -220
@@ -1,220 +0,0 @@
1
- /** this doc is generated by ./scripts/code/labels.mjs **/
2
- import { InterpretedLabelValueDefinition, LabelPreference } from '../types'
3
-
4
- export type KnownLabelValue =
5
- | '!hide'
6
- | '!warn'
7
- | '!no-unauthenticated'
8
- | 'porn'
9
- | 'sexual'
10
- | 'nudity'
11
- | 'graphic-media'
12
- | 'gore'
13
-
14
- export const DEFAULT_LABEL_SETTINGS: Record<string, LabelPreference> = {
15
- porn: 'hide',
16
- sexual: 'warn',
17
- nudity: 'ignore',
18
- 'graphic-media': 'warn',
19
- }
20
-
21
- export const LABELS: Record<KnownLabelValue, InterpretedLabelValueDefinition> =
22
- {
23
- '!hide': {
24
- identifier: '!hide',
25
- configurable: false,
26
- defaultSetting: 'hide',
27
- flags: ['no-override', 'no-self'],
28
- severity: 'alert',
29
- blurs: 'content',
30
- behaviors: {
31
- account: {
32
- profileList: 'blur',
33
- profileView: 'blur',
34
- avatar: 'blur',
35
- banner: 'blur',
36
- displayName: 'blur',
37
- contentList: 'blur',
38
- contentView: 'blur',
39
- },
40
- profile: {
41
- avatar: 'blur',
42
- banner: 'blur',
43
- displayName: 'blur',
44
- },
45
- content: {
46
- contentList: 'blur',
47
- contentView: 'blur',
48
- },
49
- },
50
- locales: [],
51
- },
52
- '!warn': {
53
- identifier: '!warn',
54
- configurable: false,
55
- defaultSetting: 'warn',
56
- flags: ['no-self'],
57
- severity: 'none',
58
- blurs: 'content',
59
- behaviors: {
60
- account: {
61
- profileList: 'blur',
62
- profileView: 'blur',
63
- avatar: 'blur',
64
- banner: 'blur',
65
- contentList: 'blur',
66
- contentView: 'blur',
67
- },
68
- profile: {
69
- avatar: 'blur',
70
- banner: 'blur',
71
- displayName: 'blur',
72
- },
73
- content: {
74
- contentList: 'blur',
75
- contentView: 'blur',
76
- },
77
- },
78
- locales: [],
79
- },
80
- '!no-unauthenticated': {
81
- identifier: '!no-unauthenticated',
82
- configurable: false,
83
- defaultSetting: 'hide',
84
- flags: ['no-override', 'unauthed'],
85
- severity: 'none',
86
- blurs: 'content',
87
- behaviors: {
88
- account: {
89
- profileList: 'blur',
90
- profileView: 'blur',
91
- avatar: 'blur',
92
- banner: 'blur',
93
- displayName: 'blur',
94
- contentList: 'blur',
95
- contentView: 'blur',
96
- },
97
- profile: {
98
- avatar: 'blur',
99
- banner: 'blur',
100
- displayName: 'blur',
101
- },
102
- content: {
103
- contentList: 'blur',
104
- contentView: 'blur',
105
- },
106
- },
107
- locales: [],
108
- },
109
- porn: {
110
- identifier: 'porn',
111
- configurable: true,
112
- defaultSetting: 'hide',
113
- flags: ['adult'],
114
- severity: 'none',
115
- blurs: 'media',
116
- behaviors: {
117
- account: {
118
- avatar: 'blur',
119
- banner: 'blur',
120
- },
121
- profile: {
122
- avatar: 'blur',
123
- banner: 'blur',
124
- },
125
- content: {
126
- contentMedia: 'blur',
127
- },
128
- },
129
- locales: [],
130
- },
131
- sexual: {
132
- identifier: 'sexual',
133
- configurable: true,
134
- defaultSetting: 'warn',
135
- flags: ['adult'],
136
- severity: 'none',
137
- blurs: 'media',
138
- behaviors: {
139
- account: {
140
- avatar: 'blur',
141
- banner: 'blur',
142
- },
143
- profile: {
144
- avatar: 'blur',
145
- banner: 'blur',
146
- },
147
- content: {
148
- contentMedia: 'blur',
149
- },
150
- },
151
- locales: [],
152
- },
153
- nudity: {
154
- identifier: 'nudity',
155
- configurable: true,
156
- defaultSetting: 'ignore',
157
- flags: [],
158
- severity: 'none',
159
- blurs: 'media',
160
- behaviors: {
161
- account: {
162
- avatar: 'blur',
163
- banner: 'blur',
164
- },
165
- profile: {
166
- avatar: 'blur',
167
- banner: 'blur',
168
- },
169
- content: {
170
- contentMedia: 'blur',
171
- },
172
- },
173
- locales: [],
174
- },
175
- 'graphic-media': {
176
- identifier: 'graphic-media',
177
- flags: ['adult'],
178
- configurable: true,
179
- defaultSetting: 'warn',
180
- severity: 'none',
181
- blurs: 'media',
182
- behaviors: {
183
- account: {
184
- avatar: 'blur',
185
- banner: 'blur',
186
- },
187
- profile: {
188
- avatar: 'blur',
189
- banner: 'blur',
190
- },
191
- content: {
192
- contentMedia: 'blur',
193
- },
194
- },
195
- locales: [],
196
- },
197
- /** @deprecated alias for `graphic-media` */
198
- gore: {
199
- identifier: 'gore',
200
- flags: ['adult'],
201
- configurable: true,
202
- defaultSetting: 'warn',
203
- severity: 'none',
204
- blurs: 'media',
205
- behaviors: {
206
- account: {
207
- avatar: 'blur',
208
- banner: 'blur',
209
- },
210
- profile: {
211
- avatar: 'blur',
212
- banner: 'blur',
213
- },
214
- content: {
215
- contentMedia: 'blur',
216
- },
217
- },
218
- locales: [],
219
- },
220
- }