1
- import { NotificationType , SheetTitle } from "@dust-tt/sparkle" ;
1
+ import { NotificationType , SheetContainer , SheetTitle } from "@dust-tt/sparkle" ;
2
2
import { SheetHeader } from "@dust-tt/sparkle" ;
3
3
import {
4
4
Avatar ,
@@ -761,10 +761,7 @@ export function ConnectorPermissionsModal({
761
761
< SheetTitle >
762
762
Manage { getDisplayNameForDataSource ( dataSource ) } connection
763
763
</ SheetTitle >
764
- </ SheetHeader >
765
-
766
- < div className = "mx-auto mt-4 flex w-full max-w-4xl grow flex-col gap-4 px-4" >
767
- < div className = "flex flex-row justify-end gap-2" >
764
+ < div className = "flex flex-row justify-end gap-2 py-1" >
768
765
{ ( isOAuthProvider ( connector . type ) ||
769
766
connector . type === "snowflake" ) && (
770
767
< Button
@@ -791,58 +788,63 @@ export function ConnectorPermissionsModal({
791
788
/>
792
789
) }
793
790
</ div >
794
- { OptionsComponent && plan && (
795
- < >
796
- < div className = "p-1 text-xl font-bold" >
797
- Connector options
798
- </ div >
799
- < div className = "p-1" >
800
- < div className = "border-y" >
801
- < OptionsComponent
802
- { ...{ owner, readOnly, isAdmin, dataSource, plan } }
803
- />
804
- </ div >
805
- </ div >
806
- </ >
807
- ) }
791
+ </ SheetHeader >
808
792
809
- < div className = "p-1 text-xl font-bold" >
810
- { CONNECTOR_CONFIGURATIONS [ connector . type ] . selectLabel }
811
- </ div >
793
+ < SheetContainer >
794
+ < div className = "flex w-full flex-col gap-4" >
795
+ { OptionsComponent && plan && (
796
+ < >
797
+ < div className = "p-1 text-xl font-bold" >
798
+ Connector options
799
+ </ div >
800
+ < div className = "p-1" >
801
+ < div className = "border-y" >
802
+ < OptionsComponent
803
+ { ...{ owner, readOnly, isAdmin, dataSource, plan } }
804
+ />
805
+ </ div >
806
+ </ div >
807
+ </ >
808
+ ) }
812
809
813
- < ContentNodeTree
814
- isSearchEnabled = {
815
- CONNECTOR_CONFIGURATIONS [ connector . type ] . isSearchEnabled
816
- }
817
- isRoundedBackground = { true }
818
- useResourcesHook = { useResourcesHook }
819
- selectedNodes = {
820
- canUpdatePermissions ? selectedNodes : undefined
821
- }
822
- setSelectedNodes = {
823
- canUpdatePermissions && ! isResourcesLoading
824
- ? setSelectedNodes
825
- : undefined
826
- }
827
- showExpand = {
828
- CONNECTOR_CONFIGURATIONS [ connector . type ] ?. isNested
829
- }
830
- />
831
-
832
- < div className = "flex justify-end gap-2 border-t pt-4" >
833
- < Button
834
- label = "Cancel"
835
- variant = "outline"
836
- onClick = { ( ) => closeModal ( false ) }
837
- />
838
- < Button
839
- label = { saving ? "Saving..." : "Save" }
840
- variant = "primary"
841
- disabled = { isUnchanged || saving }
842
- onClick = { save }
810
+ < div className = "p-1 text-xl font-bold" >
811
+ { CONNECTOR_CONFIGURATIONS [ connector . type ] . selectLabel }
812
+ </ div >
813
+
814
+ < ContentNodeTree
815
+ isSearchEnabled = {
816
+ CONNECTOR_CONFIGURATIONS [ connector . type ] . isSearchEnabled
817
+ }
818
+ isRoundedBackground = { true }
819
+ useResourcesHook = { useResourcesHook }
820
+ selectedNodes = {
821
+ canUpdatePermissions ? selectedNodes : undefined
822
+ }
823
+ setSelectedNodes = {
824
+ canUpdatePermissions && ! isResourcesLoading
825
+ ? setSelectedNodes
826
+ : undefined
827
+ }
828
+ showExpand = {
829
+ CONNECTOR_CONFIGURATIONS [ connector . type ] ?. isNested
830
+ }
843
831
/>
832
+
833
+ < div className = "flex justify-end gap-2 border-t pt-4" >
834
+ < Button
835
+ label = "Cancel"
836
+ variant = "outline"
837
+ onClick = { ( ) => closeModal ( false ) }
838
+ />
839
+ < Button
840
+ label = { saving ? "Saving..." : "Save" }
841
+ variant = "primary"
842
+ disabled = { isUnchanged || saving }
843
+ onClick = { save }
844
+ />
845
+ </ div >
844
846
</ div >
845
- </ div >
847
+ </ SheetContainer >
846
848
</ >
847
849
) }
848
850
</ SheetContent >
0 commit comments