@@ -1471,14 +1471,42 @@ function setupToggles() {
1471
1471
}
1472
1472
1473
1473
const officeAuthType = document . getElementById ( 'office_docs_authentication_type' ) ;
1474
- if ( officeAuthType ) {
1475
- officeAuthType . addEventListener ( 'change' , function ( ) {
1476
- document . getElementById ( 'office_docs_key_container' ) . style . display =
1477
- ( this . value === 'key' ) ? 'block' : 'none' ;
1474
+ const connStrGroup = document . getElementById ( 'office_docs_storage_conn_str_group' ) ;
1475
+ const urlGroup = document . getElementById ( 'office_docs_storage_url_group' ) ;
1476
+ const connStrInput = document . getElementById ( 'office_docs_storage_account_url' ) ;
1477
+ const urlInput = document . getElementById ( 'office_docs_storage_account_blob_endpoint' ) ;
1478
+
1479
+ if ( officeAuthType && connStrGroup && urlGroup && connStrInput && urlInput ) {
1480
+ officeAuthType . addEventListener ( 'change' , function ( ) {
1481
+ if ( this . value === 'managed_identity' ) {
1482
+ connStrGroup . style . display = 'none' ;
1483
+ urlGroup . style . display = '' ;
1484
+ } else {
1485
+ connStrGroup . style . display = '' ;
1486
+ urlGroup . style . display = 'none' ;
1487
+ }
1478
1488
markFormAsModified ( ) ;
1479
1489
} ) ;
1480
1490
}
1481
1491
1492
+ // Toggle visibility of connection string
1493
+ const toggleConnStrBtn = document . getElementById ( 'toggle_office_conn_str' ) ;
1494
+ if ( toggleConnStrBtn && connStrInput ) {
1495
+ toggleConnStrBtn . addEventListener ( 'click' , function ( ) {
1496
+ connStrInput . type = connStrInput . type === 'password' ? 'text' : 'password' ;
1497
+ toggleConnStrBtn . textContent = connStrInput . type === 'password' ? 'Show' : 'Hide' ;
1498
+ } ) ;
1499
+ }
1500
+
1501
+ // Toggle visibility of blob service endpoint URL
1502
+ const toggleUrlBtn = document . getElementById ( 'toggle_office_url' ) ;
1503
+ if ( toggleUrlBtn && urlInput ) {
1504
+ toggleUrlBtn . addEventListener ( 'click' , function ( ) {
1505
+ urlInput . type = urlInput . type === 'password' ? 'text' : 'password' ;
1506
+ toggleUrlBtn . textContent = urlInput . type === 'password' ? 'Show' : 'Hide' ;
1507
+ } ) ;
1508
+ }
1509
+
1482
1510
const videoAuthType = document . getElementById ( 'video_files_authentication_type' ) ;
1483
1511
if ( videoAuthType ) {
1484
1512
videoAuthType . addEventListener ( 'change' , function ( ) {
@@ -2084,7 +2112,7 @@ togglePassword('toggle_azure_apim_document_intelligence_subscription_key', 'azur
2084
2112
togglePassword ( 'toggle_office_docs_key' , 'office_docs_key' ) ;
2085
2113
togglePassword ( 'toggle_video_files_key' , 'video_files_key' ) ;
2086
2114
togglePassword ( 'toggle_audio_files_key' , 'audio_files_key' ) ;
2087
- togglePassword ( 'toggle_office_conn_str' , 'office_docs_storage_account_url ' ) ;
2115
+ togglePassword ( 'toggle_office_conn_str' , 'office_docs_storage_account_blob_endpoint ' ) ;
2088
2116
togglePassword ( 'toggle_video_conn_str' , 'video_files_storage_account_url' ) ;
2089
2117
togglePassword ( 'toggle_audio_conn_str' , 'audio_files_storage_account_url' ) ;
2090
2118
togglePassword ( 'toggle_video_indexer_api_key' , 'video_indexer_api_key' ) ;
@@ -2675,11 +2703,11 @@ function isStepComplete(stepNumber) {
2675
2703
if ( ! workspacesEnabled || ! videoEnabled ) return true ;
2676
2704
2677
2705
// Otherwise check settings
2706
+ const videoEndpoint = document . getElementById ( 'video_indexer_endpoint' ) ?. value ;
2678
2707
const videoLocation = document . getElementById ( 'video_indexer_location' ) ?. value ;
2679
2708
const videoAccountId = document . getElementById ( 'video_indexer_account_id' ) ?. value ;
2680
- const videoApiKey = document . getElementById ( 'video_indexer_api_key' ) ?. value ;
2681
2709
2682
- return videoLocation && videoAccountId && videoApiKey ;
2710
+ return videoLocation && videoAccountId && videoEndpoint ;
2683
2711
2684
2712
case 9 : // Audio support
2685
2713
const audioEnabled = document . getElementById ( 'enable_audio_file_support' ) . checked || false ;
0 commit comments