<view class="growth-record-page">
    <view class="form-container">
        <!-- Record Type -->
        <view class="form-group">
            <text class="form-label">记录类型</text>
            <view class="chip-group">
                <view class="chip {{recordType === 'growth' ? 'active' : ''}}" bindtap="setRecordType" data-type="growth">
                    <t-icon name="thumb-up" size="32rpx" />
                    <text>生长</text>
                </view>
                <view class="chip {{recordType === 'repot' ? 'active' : ''}}" bindtap="setRecordType" data-type="repot">
                    <t-icon name="swap" size="32rpx" />
                    <text>换盆</text>
                </view>
                <view class="chip {{recordType === 'pest' ? 'active' : ''}}" bindtap="setRecordType" data-type="pest">
                    <t-icon name="error-circle" size="32rpx" />
                    <text>病虫害</text>
                </view>
                <view class="chip {{recordType === 'other' ? 'active' : ''}}" bindtap="setRecordType" data-type="other">
                    <t-icon name="file" size="32rpx" />
                    <text>其他</text>
                </view>
            </view>
        </view>

        <!-- Content -->
        <view class="form-group">
            <text class="form-label">备注</text>
            <textarea 
                class="form-textarea" 
                placeholder="记录这一刻的变化..." 
                value="{{content}}" 
                bindinput="onContentInput"
                maxlength="500"
                auto-height
            />
        </view>

        <!-- Image Upload -->
        <view class="form-group">
            <text class="form-label">添加照片</text>
            <view class="record-image-upload">
                <view wx:if="{{image}}" class="uploaded-image-box">
                    <t-image src="{{image}}" mode="aspectFill" width="200rpx" height="200rpx" shape="round" />
                    <view class="remove-img-btn" bindtap="handleRemoveImage">
                        <t-icon name="close" size="32rpx" color="#FFF" />
                    </view>
                </view>
                <view wx:else class="upload-add-btn" bindtap="handleChooseImage">
                    <t-icon name="add" size="64rpx" color="#999" />
                </view>
            </view>
        </view>
    </view>

    <view class="footer-action">
        <view class="submit-btn" bindtap="handleAddRecord">
            <text>保存记录</text>
        </view>
    </view>
</view>
