Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rotate3DTransition超出布局容器显示异常 #397

Open
daoyull opened this issue Jul 30, 2024 · 0 comments
Open

Rotate3DTransition超出布局容器显示异常 #397

daoyull opened this issue Jul 30, 2024 · 0 comments

Comments

@daoyull
Copy link

daoyull commented Jul 30, 2024

视频演示

demo.mp4

视频中的代码

  <StackPanel>
        <!-- Semi 超出容器区域 -->
        <Border Theme="{DynamicResource CardBorder}">
            <Border.Styles>
                <semi:SemiTheme Locale="zh-cn" />
            </Border.Styles>
            <Expander BorderThickness="0" BorderBrush="Transparent"
                      Width="120"
                      Header="标题">
                <TextBlock
                    Text="Content"
                    TextWrapping="Wrap">
                </TextBlock>
                <Expander.ContentTransition>
                    <Rotate3DTransition Orientation="Vertical" Duration="0:0:0.5" />
                </Expander.ContentTransition>
            </Expander>
        </Border>
        <!-- Semi不超出容器区域 -->
        <Border Theme="{DynamicResource CardBorder}" Height="130">
            <Border.Styles>
                <semi:SemiTheme Locale="zh-cn" />
            </Border.Styles>
            <Expander BorderThickness="0" BorderBrush="Transparent"
                      Width="120"
                      Header="标题">
                <TextBlock
                    Text="Content"
                    TextWrapping="Wrap">
                </TextBlock>
                <Expander.ContentTransition>
                    <Rotate3DTransition Orientation="Vertical" Duration="0:0:0.5" />
                </Expander.ContentTransition>
            </Expander>
        </Border>
        <!-- 原生 -->
        <Border Theme="{DynamicResource CardBorder}" BorderThickness="1" BorderBrush="Gainsboro"
                Margin="3 10 3 0"
                Padding="10"
                CornerRadius="4">
            <Expander BorderThickness="0" BorderBrush="Transparent"
                      HorizontalAlignment="Center"
                      Width="120"
                      Header="标题">
                <TextBlock
                    Text="Content"
                    TextWrapping="Wrap">
                </TextBlock>
                <Expander.ContentTransition>
                    <Rotate3DTransition Orientation="Vertical" Duration="0:0:0.5" />
                </Expander.ContentTransition>
            </Expander>
        </Border>
    </StackPanel>

版本信息为

    <ItemGroup>
        <PackageReference Include="Avalonia" Version="11.1.1" />
        <PackageReference Include="Avalonia.Desktop" Version="11.1.1" />
        <PackageReference Include="Avalonia.Themes.Fluent" Version="11.1.1" />
        <PackageReference Include="Avalonia.Fonts.Inter" Version="11.1.1" />
        <!--Condition below is needed to remove Avalonia.Diagnostics package from build output in Release configuration.-->
        <PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.1.1" />
        <PackageReference Include="Semi.Avalonia" Version="11.1.0" />
    </ItemGroup>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant