chore: add doc_lift for authorization.sources

doc_lift is to make the doc render application to lift
this field to the root level and force the field's doc
to refernec it instead of expanding the structs in a nested way
This commit is contained in:
Zaiming (Stone) Shi 2023-04-03 13:41:13 +02:00
parent 082dfc02c9
commit e978d86c86
2 changed files with 4 additions and 2 deletions

View File

@ -1,7 +1,7 @@
%% -*- mode: erlang -*- %% -*- mode: erlang -*-
{application, emqx_authz, [ {application, emqx_authz, [
{description, "An OTP application"}, {description, "An OTP application"},
{vsn, "0.1.15"}, {vsn, "0.1.16"},
{registered, []}, {registered, []},
{mod, {emqx_authz_app, []}}, {mod, {emqx_authz_app, []}},
{applications, [ {applications, [

View File

@ -492,7 +492,9 @@ authz_fields() ->
?ARRAY(?UNION(UnionMemberSelector)), ?ARRAY(?UNION(UnionMemberSelector)),
#{ #{
default => [], default => [],
desc => ?DESC(sources) desc => ?DESC(sources),
%% doc_lift is force a root level reference instead of nesting sub-structs
extra => #{doc_lift => true}
} }
)} )}
]. ].