This commit is contained in:
2026-05-19 17:39:03 +07:00
parent bf0ebe447d
commit 5da832bb57
559 changed files with 69543 additions and 1 deletions

View File

@@ -0,0 +1,62 @@
.rive-inspector {
padding-top: 9px;
}
.rive-inspector__section {
margin-bottom: 9px;
margin-top: 3px;
}
.rive-inspector__foldout {
}
.rive-inspector__field {
margin-bottom: 3px;
margin-left: 3px;
}
.rive-inspector__field > Label {
min-width: 117px;
}
.rive-inspector__field-container {
flex-direction: row;
align-items: center;
}
.rive-inspector__field-content {
flex: 1 1 auto;
}
.rive-inspector__field-help-button {
width: 20px;
height: 20px;
padding: 0;
margin-left: 4px;
flex-shrink: 0;
justify-content: center;
align-items: center;
background-color: rgba(0, 0, 0, 0);
border-width: 0;
}
.rive-inspector__field-help-button > Image {
width: 14px;
height: 14px;
}
.rive-inspector__field-help-button:hover {
background-color: rgba(0, 0, 0, 0.08);
}
.rive-inspector__section-label {
-unity-font-style: bold;
margin-bottom: 4px;
margin-left: 5.2px;
}
.unity-foldout__input > Label {
-unity-font-style: bold;
margin-left: 1px;
}

View File

@@ -0,0 +1,18 @@
fileFormatVersion: 2
guid: cc66ac87f8ecb4e3c91384370163ee7b
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 2
userData:
assetBundleName:
assetBundleVariant:
script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
disableValidation: 0
AssetOrigin:
serializedVersion: 1
productId: 350858
packageName: Rive
packageVersion: 0.4.2
assetPath: Packages/app.rive.rive-unity/Editor/Components/Styles/RiveInspectorStyleSheet.uss
uploadId: 896810

View File

@@ -0,0 +1,63 @@
using UnityEditor;
using UnityEngine.UIElements;
namespace Rive
{
/// <summary>
/// Helper class for styling Rive components.
/// </summary>
internal class StyleHelper
{
// USS Class Names
/// <summary>
/// The block class name for the Rive inspector.
/// </summary>
public const string CLASS_BLOCK = "rive-inspector";
/// <summary>
/// The element class name for sections within the Rive inspector.
/// </summary>
public const string CLASS_SECTION = "rive-inspector__section";
/// <summary>
/// The element class name for section labels within the Rive inspector.
/// </summary>
public const string CLASS_SECTION_LABEL = "rive-inspector__section-label";
/// <summary>
/// The element class name for fields within the Rive inspector.
/// </summary>
public const string CLASS_FIELD = "rive-inspector__field";
/// <summary>
/// Container that wraps a field and its optional help button.
/// </summary>
public const string CLASS_FIELD_CONTAINER = "rive-inspector__field-container";
/// <summary>
/// Class name applied to the primary field element inside a container.
/// </summary>
public const string CLASS_FIELD_CONTENT = "rive-inspector__field-content";
/// <summary>
/// Class name applied to the help/info buttons.
/// </summary>
public const string CLASS_FIELD_HELP_BUTTON = "rive-inspector__field-help-button";
private static StyleSheet s_StyleSheet;
public static StyleSheet StyleSheet
{
get
{
if (s_StyleSheet == null)
{
string ussPath = "Packages/app.rive.rive-unity/Editor/Components/Styles/RiveInspectorStyleSheet.uss";
s_StyleSheet = AssetDatabase.LoadAssetAtPath<StyleSheet>(ussPath);
}
return s_StyleSheet;
}
}
}
}

View File

@@ -0,0 +1,18 @@
fileFormatVersion: 2
guid: 8a09ca9bb7cb94661be11fbfb6e25ba0
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
AssetOrigin:
serializedVersion: 1
productId: 350858
packageName: Rive
packageVersion: 0.4.2
assetPath: Packages/app.rive.rive-unity/Editor/Components/Styles/StyleHelper.cs
uploadId: 896810