mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2025-07-27 10:56:57 +00:00
24 lines
603 B
Dart
24 lines
603 B
Dart
![]() |
class ShareConstants {
|
||
|
static const String publishBaseUrl = 'https://appflowy.com';
|
||
|
static const String shareBaseUrl = 'https://appflowy.com/app';
|
||
|
|
||
|
static String buildPublishUrl({
|
||
|
required String nameSpace,
|
||
|
required String publishName,
|
||
|
}) {
|
||
|
return '$publishBaseUrl/$nameSpace/$publishName';
|
||
|
}
|
||
|
|
||
|
static String buildShareUrl({
|
||
|
required String workspaceId,
|
||
|
required String viewId,
|
||
|
String? blockId,
|
||
|
}) {
|
||
|
final url = '$shareBaseUrl/$workspaceId/$viewId';
|
||
|
if (blockId == null || blockId.isEmpty) {
|
||
|
return url;
|
||
|
}
|
||
|
return '$url?blockId=$blockId';
|
||
|
}
|
||
|
}
|