File tree Expand file tree Collapse file tree 3 files changed +18
-10
lines changed Expand file tree Collapse file tree 3 files changed +18
-10
lines changed Original file line number Diff line number Diff line change 1
1
<script lang =" ts" >
2
+ import Button from ' $lib/components/Button.svelte'
2
3
import Cell from ' ./TableCell.svelte'
3
4
import { categories } from ' ./categories'
4
5
import { companies } from ' ./companies'
5
6
6
7
let showExplanation = false
7
8
</script >
8
9
9
- <label >
10
- <input type ="checkbox" bind:checked ={showExplanation } />
11
- Show explanations
12
- </label >
10
+ <Button on:click ={() => (showExplanation = ! showExplanation )}>Toggle explanations</Button >
13
11
14
12
<table class ={showExplanation ? ' table--big' : ' ' }>
15
13
<thead >
Original file line number Diff line number Diff line change 20
20
}
21
21
}
22
22
}
23
+
24
+ function maybeShowTooltip() {
25
+ if (! showExplanation ) {
26
+ showTooltip = true
27
+ }
28
+ }
29
+
30
+ function handleClick() {
31
+ ! showExplanation && (showExplanation = ! showExplanation )
32
+ }
23
33
</script >
24
34
25
35
<td
26
- on:mouseover ={() => ( showTooltip = true ) }
36
+ on:mouseover ={maybeShowTooltip }
27
37
on:mouseout ={() => (showTooltip = false )}
28
- on:focus ={() => ( showTooltip = true ) }
38
+ on:focus ={maybeShowTooltip }
29
39
on:blur ={() => (showTooltip = false )}
30
- on:click ={() => ( showExplanation = ! showExplanation ) }
40
+ on:click ={handleClick }
31
41
class ={showExplanation ? ' ' : ' enable-tooltips' }
32
42
>
33
43
{#if title !== undefined }
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ const companiesSource: Company[] = [
62
62
explanation :
63
63
// https://corporateeurope.org/en/2023/11/byte-byte
64
64
'Microsoft has lobbied to shift the burden of responsibility onto users of AI instead of the ones building the AI.' ,
65
- score : 3
65
+ score : 2
66
66
} ,
67
67
deployment : {
68
68
explanation :
@@ -111,7 +111,7 @@ const companiesSource: Company[] = [
111
111
// https://pitchbook.com/news/articles/generative-AI-Capitol-Hill-VC
112
112
explanation :
113
113
"Anthropic has spent (a little) money lobbying, but it's unclear what they are pushing for." ,
114
- score : 7
114
+ score : 5
115
115
} ,
116
116
deployment : {
117
117
explanation :
@@ -135,7 +135,7 @@ const companiesSource: Company[] = [
135
135
} ,
136
136
lobby : {
137
137
explanation : 'No lobbying as far as we know of yet.' ,
138
- score : 7
138
+ score : 5
139
139
} ,
140
140
deployment : {
141
141
explanation : 'Not sure tbd' ,
You can’t perform that action at this time.
0 commit comments