Tavenem.Wiki
0.26.13-preview
Prefix Reserved
See the version list below for details.
dotnet add package Tavenem.Wiki --version 0.26.13-preview
NuGet\Install-Package Tavenem.Wiki -Version 0.26.13-preview
<PackageReference Include="Tavenem.Wiki" Version="0.26.13-preview" />
paket add Tavenem.Wiki --version 0.26.13-preview
#r "nuget: Tavenem.Wiki, 0.26.13-preview"
// Install Tavenem.Wiki as a Cake Addin #addin nuget:?package=Tavenem.Wiki&version=0.26.13-preview&prerelease // Install Tavenem.Wiki as a Cake Tool #tool nuget:?package=Tavenem.Wiki&version=0.26.13-preview&prerelease
Tavenem.Wiki
Tavenem.Wiki is a .NET wiki library.
Unlike many wiki software packages, this main library is implementation-agnostic. It provides a set of core features which can be used to build a web-based wiki, a desktop application, a distributed cloud app with native clients, or any other architecture desired.
Installation
Tavenem.Wiki is available as a NuGet package.
Configuration
The WikiOptions
object is used to control the behavior of the wiki. It is expected as a parameter
to various methods, and in most implementations is expected to be provided by dependency injection
after being configured during initialization.
Most of the properties of this class are not expected to change once a wiki has gone into operation. Doing so can cause existing wiki pages to become inaccessible, or to be formatted incorrectly.
AboutPageTitle
*: The title of the main about page. Default is "About".CategoriesTitle
: The name of the article on categories in the main wiki. Default is "Categories".CategoryNamespace
: The name of the categories namespace. Default is "Category".ContactPageTitle
*: The title of the main contact page. Default is "Contact".ContentsPageTitle
*: The title of the main contents page. Default is "Contents".CopyrightPageTitle
*: The title of the main copyright page. Default is "Copyright".CustomAdminNamespaces
: An optional collection of namespaces which may not be assigned to pages by non-admin users.The
AdminNamespaces
read-only property may be used to get the full list, which includes the namespace assigned toSystemNamespace
automatically.CustomReservedNamespaces
: An optional collection of namespaces which may not be assigned to pages by users.The
ReservedNamespaces
read-only property may be used to get the full list, which includes the namespace assigned toFileNamespace
automatically.DefaultAnonymousPermission
: The default permission granted to an anonymous user for wiki content with no configured access control.This defaults to
Read
, which allows anonymous users to view any content for which no specific access has been configured. It can be set toNone
to disable anonymous browsing, and require all users to sign in prior to viewing any content.Note that anonymous users cannot make any changes regardless of this setting. A specific editor is required for all content creation and revision.
DefaultRegisteredPermission
: The default permission granted to a registered user for wiki content with no configured access control.This defaults to
All
, which allows registered users full access when no specific access controls take precedence.DefaultTableOfContentsDepth
: The default number of levels of nesting shown in an article's table of contents. Can be overridden by specifying the level for a given article. Default is 3.DefaultTableOfContentsTitle
: The default title of tables of contents. Default is "Contents".FileNamespace
: The name of the file namespace. Default is "File".GetDomainPermission
: When a user attempts to interact with an article in a domain (including viewing, creating, editing, or deleting items), this function is invoked (if provided) to determine the permissions the user has for that domain.Receives the user's ID and the name of the domain as parameters, and should return a
WikiPermission
enum value.GroupNamespace
: The name of the user group namespace. Default is "Group".HelpPageTitle
*: The title of the main help page. Default is "Help".LinkTemplate
: A string added to all wiki links, if non-empty. The string '{LINK}', if included, will be replaced by the full article title being linked.MainPageTitle
: The title of the main page for any namespace (shown when no article title is explicitly requested). If omitted "Main" will be used.MaxFileSize
: The maximum size (in bytes) of uploaded files. Default is 5,000,000 (5 MB).Setting this to a value less than or equal to zero effectively prevents file uploads.
MaxFileSizeString
: Read-only. Gets a string representing theMaxFileSize
in a reasonable unit (GB for large sizes, down to bytes for small ones).MinimumTableOfContentsHeadings
: The minimum number of headings required in an article to display a table of contents by default. Can be overridden by specifying the location of a table of contents explicitly for a given article. Default is 3.OnCreated
: An optional callback invoked when a new article (including categories and files) is created.Receives the new article as a parameter.
OnDeleted
: An optional callback invoked when an article (including categories and files) is deleted.Receives the deleted article, the original owner, and the new owner as parameters.
OnEdited
: An optional callback invoked when an article (including categories and files) is edited (not including deletion ifOnDeleted
is provided).Receives the deleted article, the revision which was applied, the original owner, and the new owner as parameters.
PolicyPageTitle
*: The title of the main policy page. Default is "Policies".Postprocessors
: A collection of preprocessors which transform the HTML of an article after it is parsed from markdown but before it is sanitized.Processors are run in the order they are added to the collection.
ScriptNamespace
: The name of the script namespace. Default is "Script".SiteName
: The name of the wiki. Displayed as a subheading below each article title. Default is "a NeverFoundry wiki".SystemNamespace
: The name of the system namespace. Default is "System".TransclusionNamespace
: The name of the transclusion namespace. Default is "Transclusion".When a transclusion omits the namespace, this namespace is assumed. To transclude a page from the default (empty) namespace, a transclusion may use a single hyphen as the namespace. The hyphen will be replaced during transclusion by the empty namespace. If your wiki actually has a namespace that uses a single hyphen as its name, pages may be transcluded from it by escaping the hyphen with a backslash character: '
\-
'.UserNamespace
: The name of the user namespace. Default is "User".UserDomains
: If set totrue
each user (and only that user) is automatically granted full permission in a domain with the same name as their user ID. TheGetDomainPermission
function, theWikiUser.AllowedViewDomains
property, and theWikiGroup.AllowedViewDomains
property will still be checked for other users attempting to access content in such domains, but the user with the matching ID will always be granted all permissions automatically. A possible use for user domains is as a "scratch-pad" area where articles can be drafted and tested prior to publication.WikiLinkPrefix
: A prefix added before wiki links (to distinguish them from other pages on the same server). Default is "Wiki".May be set to
null
or an emptystring
, which omits any prefix from generated URLs.
*This property may be set to null
or an empty string
to disable the associated wiki page.
The associated page is expected in the system namespace, and is not expected to be in a domain
Markup
The Tavenem Wiki syntax is a custom flavor of markdown. It implements all the features of CommonMark, as well as many others. The implementation uses Markdig, and details of most extensions to standard CommonMark can be found on its GitHub page.
Roadmap
Tavenem.Wiki is currently in a prerelease state. Development is ongoing, and breaking changes are possible before the first production release.
No release date is currently set for v1.0 of Tavenem.Wiki. The project is currently in a "wait and see" phase while Tavenem.DataStore (a dependency of Tavenem.Wiki) is in prerelease. When that project has a stable release, a production release of Tavenem.Wiki will follow.
Contributing
Contributions are always welcome. Please carefully read the contributing document to learn more before submitting issues or pull requests.
Code of conduct
Please read the code of conduct before engaging with our community, including but not limited to submitting or replying to an issue or pull request.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- Handlebars.Net (>= 2.1.6)
- HtmlSanitizer (>= 8.1.870)
- Jint (>= 4.0.3)
- Lucene.Net (>= 4.8.0-beta00016)
- Lucene.Net.Analysis.Common (>= 4.8.0-beta00016)
- Lucene.Net.Highlighter (>= 4.8.0-beta00016)
- Lucene.Net.QueryParser (>= 4.8.0-beta00016)
- Markdig (>= 0.37.0)
- Microsoft.Extensions.Caching.Abstractions (>= 8.0.0)
- System.Text.Json (>= 8.0.5)
- Tavenem.DataStore (>= 2.0.4)
- Tavenem.DiffPatchMerge (>= 1.0.0)
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Tavenem.Wiki:
Package | Downloads |
---|---|
Tavenem.Wiki.Blazor.Client
An implementation of Tavenem.Wiki for Blazor. |
|
Tavenem.Wiki.Blazor.Shared
An implementation of Tavenem.Wiki for Blazor. |
|
Tavenem.Wiki.Mvc
An implementation of Tavenem.Wiki for ASP.NET MVC. |
|
Tavenem.Wiki.Web
An auxilliary library for Tavenem.Wiki with interfaces and classes for web implementations. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
0.28.3-preview | 50 | 12/3/2024 |
0.28.2-preview | 56 | 11/26/2024 |
0.28.1-preview | 43 | 11/26/2024 |
0.28.0-preview | 56 | 11/22/2024 |
0.27.2-preview | 53 | 11/21/2024 |
0.27.1-preview | 40 | 11/21/2024 |
0.27.0-preview | 48 | 11/20/2024 |
0.26.14-preview | 50 | 11/15/2024 |
0.26.13-preview | 51 | 11/15/2024 |
0.26.12-preview | 48 | 11/15/2024 |
0.26.11-preview | 47 | 11/14/2024 |
0.26.10-preview | 50 | 11/13/2024 |
0.26.9-preview | 44 | 11/13/2024 |
0.26.8-preview | 48 | 11/12/2024 |
0.26.7-preview | 56 | 11/11/2024 |
0.26.6-preview | 57 | 11/8/2024 |
0.26.5-preview | 52 | 11/7/2024 |
0.26.4-preview | 59 | 11/6/2024 |
0.26.3-preview | 53 | 10/31/2024 |
0.26.2-preview | 82 | 10/18/2024 |
0.26.1-preview | 75 | 10/18/2024 |
0.26.0-preview | 81 | 8/22/2024 |
0.25.4-preview | 93 | 3/28/2024 |
0.25.3-preview | 70 | 3/25/2024 |
0.25.2-preview | 70 | 3/25/2024 |
0.25.1-preview | 60 | 3/25/2024 |
0.25.0-preview | 65 | 3/22/2024 |
0.24.4-preview | 71 | 2/21/2024 |
0.24.3-preview | 77 | 2/20/2024 |
0.24.2-preview | 67 | 2/20/2024 |
0.24.1-preview | 74 | 2/19/2024 |
0.24.0-preview | 162 | 11/27/2023 |
0.23.0-preview | 112 | 9/8/2023 |
0.22.2-preview | 108 | 8/14/2023 |
0.22.1-preview | 104 | 8/9/2023 |
0.22.0-preview | 97 | 8/4/2023 |
0.21.0-preview | 116 | 7/26/2023 |
0.20.1-preview | 90 | 4/25/2023 |
0.20.0-preview | 106 | 3/3/2023 |
0.19.4-preview | 110 | 3/2/2023 |
0.19.3-preview | 120 | 3/1/2023 |
0.19.2-preview | 124 | 2/3/2023 |
0.19.1-preview | 109 | 1/12/2023 |
0.19.0-preview | 122 | 1/11/2023 |
0.18.6-preview | 109 | 1/9/2023 |
0.18.5-preview | 110 | 1/9/2023 |
0.18.4-preview | 120 | 1/9/2023 |
0.18.3-preview | 111 | 1/6/2023 |
0.18.2-preview | 105 | 1/6/2023 |
0.18.1-preview | 114 | 1/6/2023 |
0.18.0-preview | 112 | 1/6/2023 |
0.17.0-preview | 116 | 1/3/2023 |
0.16.0-preview | 106 | 1/3/2023 |
0.15.0-preview | 105 | 11/22/2022 |
0.14.1-preview | 106 | 11/8/2022 |
0.14.0-preview | 105 | 11/7/2022 |
0.13.3-preview | 106 | 11/4/2022 |
0.13.2-preview | 105 | 11/3/2022 |
0.13.1-preview | 100 | 10/31/2022 |
0.12.4-preview | 99 | 10/31/2022 |
0.12.3-preview | 106 | 10/31/2022 |
0.12.2-preview | 105 | 10/26/2022 |
0.12.1-preview | 100 | 10/25/2022 |
0.12.0-preview | 104 | 10/25/2022 |
0.11.1-preview | 132 | 9/8/2022 |
0.11.0-preview | 116 | 9/8/2022 |
0.10.0-preview | 116 | 9/2/2022 |
0.9.0-preview | 111 | 9/1/2022 |
0.8.10-preview | 115 | 8/26/2022 |
0.8.9-preview | 114 | 8/25/2022 |
0.8.8-preview | 118 | 8/25/2022 |
0.8.7-preview | 124 | 8/25/2022 |
0.8.6-preview | 118 | 8/25/2022 |
0.8.5-preview | 120 | 8/25/2022 |
0.8.4-preview | 119 | 8/24/2022 |
0.8.3-preview | 116 | 8/24/2022 |
0.8.2-preview | 127 | 8/24/2022 |
0.8.1-preview | 121 | 8/24/2022 |
0.8.0-preview | 117 | 8/24/2022 |
0.7.2-preview | 121 | 8/22/2022 |
0.7.1-preview | 115 | 8/19/2022 |
0.7.0-preview | 118 | 8/19/2022 |
0.6.1-preview | 119 | 8/19/2022 |
0.6.0-preview | 126 | 8/15/2022 |
0.5.0-preview | 141 | 8/3/2022 |
0.4.0-preview | 162 | 8/31/2021 |
0.3.2-preview | 169 | 5/21/2021 |
0.3.1-preview | 167 | 4/26/2021 |
0.3.0-preview | 160 | 4/26/2021 |
0.2.3-preview | 156 | 4/15/2021 |
0.2.2-preview | 151 | 4/15/2021 |
0.2.1-preview | 157 | 4/15/2021 |
0.2.0-preview | 167 | 4/14/2021 |
0.1.0-preview | 177 | 4/11/2021 |