Commit fcee9f4
feat: add endpoint-based HTTP Basic Authentication support with unified SPARQL Endpoints management (#55)
* Initial plan
* feat: add basic authentication support - core implementation
- Add BasicAuthConfig type to RequestConfig interface
- Add basicAuth field to request configuration with username/password
- Implement Authorization header generation in sparql.ts
- Add Authentication tab in Settings modal with username/password inputs
- Add security notice about localStorage and HTTPS usage
- Add proper theme-aware styling for auth inputs
- Build successfully compiles with new types
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* feat: add documentation and tests for basic authentication
- Add comprehensive user and developer documentation
- Create unit tests for base64 encoding and auth header format
- Document security considerations and best practices
- Add code examples for various authentication scenarios
- Include troubleshooting guide
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* fix: address code review feedback for basic auth
- Add error handling for basicAuth function calls
- Ensure authentication is cleared when credentials are incomplete
- Improve consistency of authentication state management
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* docs: integrate basic auth into user and developer guides
- Move basic auth documentation from standalone file into existing guides
- Add authentication section to user guide after Settings Modal
- Add authentication section to developer guide in Request Configuration
- Remove standalone docs/basic-authentication.md file
- Keep user and developer documentation together in their respective guides
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* feat: change layout of settings to vertical sections
* refactor: change authentication from tab-based to endpoint-based (WIP)
- Add EndpointConfig interface for endpoint-based storage with authentication
- Update PersistentConfig to store endpoint configurations instead of tab-based auth
- Add methods to manage endpoint configs (get, set, add/update, delete)
- Modify Tab to inject authentication from endpoint config into request config
- Add auto-tracking of accessed endpoints
- Rename "Endpoint Buttons" tab to "SPARQL Endpoints" in settings modal
- Remove standalone "Authentication" tab from settings modal
- Preparing for comprehensive SPARQL Endpoints UI (next commit)
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* feat: implement SPARQL Endpoints UI with authentication per endpoint
- Create comprehensive SPARQL Endpoints settings tab
- Replace separate Authentication and Endpoint Buttons tabs
- Add endpoints table with columns: Endpoint, Label, Button, Authentication, Actions
- Implement authentication modal per endpoint (designed for future auth types)
- Add auto-tracking of accessed endpoints
- Update endpoint buttons to use new endpointConfigs with showAsButton flag
- Add complete CSS styling for table and modal with theme support
- Maintain backwards compatibility with legacy customEndpointButtons
- Build successfully compiles
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* docs: update user and developer guides for endpoint-based authentication
- Update user guide to reflect SPARQL Endpoints tab instead of Authentication tab
- Document endpoint-based storage model
- Add instructions for managing endpoints and configuring authentication per endpoint
- Update developer guide with endpoint configuration API examples
- Remove references to per-tab authentication
- Emphasize that authentication is now shared across tabs using the same endpoint
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* fix: modal settings window layout issues
* feat: add manual endpoint addition in SPARQL Endpoints settings
- Add "Add New Endpoint" form with URL input and "+ Add Endpoint" button
- Allow users to manually add endpoints instead of only auto-tracking
- Validate URL format before adding
- Check for duplicate endpoints
- Show improved empty message: "No endpoints yet. Add one below or access an endpoint to have it automatically tracked."
- Add themed CSS styling for form (background, borders, button)
- Full theme support with CSS custom properties for light/dark modes
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
* Update packages/yasgui/src/TabSettingsModal.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update packages/yasqe/src/sparql.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update packages/yasqe/src/sparql.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix: address code review feedback
- Add check for existing Authorization header before adding basic auth
- Only inject endpoint-based auth if basicAuth not already set programmatically
- Properly delete authentication field when set to undefined in updates
- Add aria-label to "Show as Button" checkbox for accessibility
- Update documentation to clarify endpoint-based (not tab-based) authentication
- Add security warnings about localStorage credential storage
- Recommend secure alternatives (session tokens, OAuth) in examples
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: MathiasVDA <15101339+MathiasVDA@users.noreply.github.com>
Co-authored-by: Mathias Vanden Auweele <mathias@matdata.eu>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>1 parent bb83d54 commit fcee9f4
File tree
12 files changed
+1300
-169
lines changed- docs
- packages
- yasgui/src
- yasqe/src
- __tests__
12 files changed
+1300
-169
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
904 | 904 | | |
905 | 905 | | |
906 | 906 | | |
| 907 | + | |
| 908 | + | |
| 909 | + | |
| 910 | + | |
| 911 | + | |
| 912 | + | |
| 913 | + | |
| 914 | + | |
907 | 915 | | |
908 | 916 | | |
909 | 917 | | |
| |||
937 | 945 | | |
938 | 946 | | |
939 | 947 | | |
| 948 | + | |
| 949 | + | |
| 950 | + | |
| 951 | + | |
| 952 | + | |
| 953 | + | |
| 954 | + | |
| 955 | + | |
| 956 | + | |
| 957 | + | |
| 958 | + | |
| 959 | + | |
| 960 | + | |
| 961 | + | |
| 962 | + | |
| 963 | + | |
| 964 | + | |
| 965 | + | |
| 966 | + | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
| 977 | + | |
| 978 | + | |
| 979 | + | |
| 980 | + | |
| 981 | + | |
| 982 | + | |
| 983 | + | |
| 984 | + | |
| 985 | + | |
| 986 | + | |
| 987 | + | |
| 988 | + | |
| 989 | + | |
| 990 | + | |
| 991 | + | |
| 992 | + | |
| 993 | + | |
| 994 | + | |
| 995 | + | |
| 996 | + | |
| 997 | + | |
| 998 | + | |
| 999 | + | |
| 1000 | + | |
| 1001 | + | |
| 1002 | + | |
| 1003 | + | |
| 1004 | + | |
| 1005 | + | |
| 1006 | + | |
| 1007 | + | |
| 1008 | + | |
| 1009 | + | |
| 1010 | + | |
| 1011 | + | |
| 1012 | + | |
| 1013 | + | |
| 1014 | + | |
| 1015 | + | |
| 1016 | + | |
| 1017 | + | |
| 1018 | + | |
| 1019 | + | |
| 1020 | + | |
| 1021 | + | |
| 1022 | + | |
| 1023 | + | |
| 1024 | + | |
| 1025 | + | |
| 1026 | + | |
| 1027 | + | |
| 1028 | + | |
| 1029 | + | |
| 1030 | + | |
| 1031 | + | |
| 1032 | + | |
| 1033 | + | |
| 1034 | + | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
| 1069 | + | |
| 1070 | + | |
| 1071 | + | |
| 1072 | + | |
| 1073 | + | |
| 1074 | + | |
| 1075 | + | |
| 1076 | + | |
| 1077 | + | |
| 1078 | + | |
| 1079 | + | |
| 1080 | + | |
| 1081 | + | |
| 1082 | + | |
| 1083 | + | |
| 1084 | + | |
| 1085 | + | |
| 1086 | + | |
| 1087 | + | |
| 1088 | + | |
| 1089 | + | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
| 1093 | + | |
| 1094 | + | |
| 1095 | + | |
| 1096 | + | |
| 1097 | + | |
| 1098 | + | |
| 1099 | + | |
| 1100 | + | |
| 1101 | + | |
| 1102 | + | |
| 1103 | + | |
| 1104 | + | |
| 1105 | + | |
| 1106 | + | |
| 1107 | + | |
| 1108 | + | |
| 1109 | + | |
| 1110 | + | |
| 1111 | + | |
| 1112 | + | |
| 1113 | + | |
| 1114 | + | |
| 1115 | + | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
| 1120 | + | |
| 1121 | + | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
| 1130 | + | |
| 1131 | + | |
| 1132 | + | |
| 1133 | + | |
| 1134 | + | |
| 1135 | + | |
| 1136 | + | |
| 1137 | + | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
940 | 1144 | | |
941 | 1145 | | |
942 | 1146 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
511 | 511 | | |
512 | 512 | | |
513 | 513 | | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
514 | 520 | | |
515 | 521 | | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
516 | 579 | | |
517 | 580 | | |
518 | 581 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
304 | 304 | | |
305 | 305 | | |
306 | 306 | | |
| 307 | + | |
307 | 308 | | |
308 | 309 | | |
309 | 310 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| 28 | + | |
27 | 29 | | |
28 | 30 | | |
29 | 31 | | |
| |||
163 | 165 | | |
164 | 166 | | |
165 | 167 | | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
166 | 208 | | |
167 | 209 | | |
168 | 210 | | |
| |||
0 commit comments