using Microsoft.Extensions.Options;
using OrchardCore.ResourceManagement;

namespace Oap.Theme;

public class ResourceManagementOptionsConfiguration : IConfigureOptions<ResourceManagementOptions>
{
	static ResourceManagementOptionsConfiguration()
	{
		m_manifest = new ResourceManifest();

		m_manifest
			.DefineStyle("OapTheme-styles")
			.SetUrl("~/Oap.Theme/site.css")
			.SetVersion("1.0.0");
	}

	public void Configure(ResourceManagementOptions options)
	{
		options.ResourceManifests.Add(m_manifest);
	}

	private static ResourceManifest m_manifest;
}
